Official plugins that extend tk with additional commands.
Plugins are executables named tk-<cmd> or ticket-<cmd> in $PATH. This repo uses the ticket- prefix for consistency.
Conventional metadata in the first 10 lines, read by the packaging scripts:
#!/usr/bin/env bash # tk-plugin: sync tickets with GitHub issues # tk-plugin-version: 1.0.0 set -euo pipefail # implementation here
Plugins receive:
TICKETS_DIR: absolute path to the.tickets/directory when tk found one; otherwise unset, or whatever value the caller had setTK_SCRIPT: absolute path to thetkscript
Use $TK_SCRIPT super <cmd> to call built-ins without recursing into plugins:
#!/usr/bin/env bash # tk-plugin: wrapper that creates tickets with defaults # tk-plugin-version: 1.0.0 "$TK_SCRIPT" super create "$@" --type task --priority 1
Copy or link the plugin into a directory on your PATH, for example
~/.local/bin:
ln -s "$PWD/plugins/ticket-open" ~/.local/bin/ticket-open tk open web-3k9f
- Create
plugins/ticket-<name>with the metadata comments shown above. chmod +x plugins/ticket-<name>- Pick a name that is not a built-in command, or it will replace the
built-in (
tk super <cmd>still reaches the built-in).