tk tracks feature work as plain markdown files, one ticket per file, edited in
place. It indexes, queues, and locates tickets; the filesystem is the editor.
The implementation is the source of truth.
macOS and Linux only. Windows is not supported — there is no flock or path
substitute, and tk fails with a clear startup error on an unsupported OS rather
than half-running. This is a deliberate v1 scope limit.
brew tap p3bot/tap
brew trust p3bot/tap
brew install p3bot/tap/tkgo install github.com/p3bot/tk/cmd/tk@latestgo build ./...
go build -o tk ./cmd/tkRequires Go 1.26. Pure Go, no cgo. The external git binary is used only to
derive a code-root / git-root; it is shelled out, never linked.
A scope is a directory of ticket markdown files plus its tk.cue (the scope's
name, auto-commit mode, and schema). Scopes are registered per machine in the XDG
config directory (${XDG_CONFIG_HOME:-~/.config}/tk/).
tk scope init <dir> (--name <name> | --auto-name) [--code-root <path>] [--auto-commit]
tk scope import <dir> [--code-root <path>]
tk scope rebind <dir> --name <name> [--code-root <path>]
tk scope forget <name>
tk scope list # bare `tk scope` and `tk scopes` also run listinitcreates and registers a new scope, writing a minimaltk.cueand a.gitignorecovering.tk.lock. Exactly one of--name/--auto-nameis required. In a dedicated tk repo, pass--auto-commit(omitting it registers repo-driven).importregisters an existing on-disk scope, files in place; its name and auto-commit mode come from the on-disktk.cue.rebindrewrites a registered scope's paths after a move or clone.forgetunregisters a scope (registry and lens entries only); it never touches the scope's files.listprints parse-stable TSV, one line per scope:name\tdir\troot\tmode, wheremodeistk-driven,repo-driven,plain-files, orunknown.
- stdout is a path or closed TSV; diagnostics and closed tokens go to stderr.
- Exit
0success;2for usage / bad CLI input; other failures are generic non-zero. There is no--jsonand no colour on stdout.NO_COLORsuppresses all ANSI.
| Task | Command |
|---|---|
| Build | go build ./... |
| Test | go test ./... |
| Format | gofmt -w . |
| Vet | go vet ./... |
| Lint | golangci-lint run ./... |