diff --git a/.opencode/agent/feature-planner-agent.md b/.opencode/agent/feature-planner-agent.md index 93af048..9a84855 100644 --- a/.opencode/agent/feature-planner-agent.md +++ b/.opencode/agent/feature-planner-agent.md @@ -17,7 +17,7 @@ permissions: bash: "sudo *": "deny" skill: - "worklane_kanban": "allow" + "worklane": "allow" --- # Feature Planner Agent diff --git a/.opencode/agent/reviewing-agent.md b/.opencode/agent/reviewing-agent.md index 50276c5..58bfedb 100644 --- a/.opencode/agent/reviewing-agent.md +++ b/.opencode/agent/reviewing-agent.md @@ -17,7 +17,7 @@ permissions: bash: "sudo *": "deny" skill: - "worklane_kanban": "allow" + "worklane": "allow" "testing-skill": "allow" --- diff --git a/.opencode/skill/worklane-kanban-skill/SKILL.md b/.opencode/skill/worklane-kanban-skill/SKILL.md deleted file mode 100644 index 5c78309..0000000 --- a/.opencode/skill/worklane-kanban-skill/SKILL.md +++ /dev/null @@ -1,223 +0,0 @@ ---- -id: worklane_kanban -name: worklane_kanban -version: 1.0.0 -description: > - Creates Kanban-style tickets in Worklane using the `worklane add` CLI command. - Supports listing tickets with `worklane ls`. Both commands support title, description, - acceptance criteria, implementation plan, tags, due date, owner assignment, and status filtering. -rendering: - strategy: cli_args - join_arrays_with: "," - omit_empty: true ---- - -# Worklane Kanban Skill - -Use this skill when creating, listing, or managing Kanban-style tickets via the `worklane` CLI. - -When asked to "create a ticket", use the `worklane add` command. -When using backticks in the command arguments, escape them so the terminal doesn't execute them. - -When asked to "implement", "work on" or "read" a ticket, use the `worklane show` command. - -## Commands - -### `worklane add` - -Add a new ticket to the backlog. - -**Required:** -- `--title` (or `-t`): Ticket title - -**Optional:** -- `--description` (or `-d`): Ticket description -- `--acceptance` (or `-a`): Acceptance criteria (repeat flag for each criterium) -- `--plan` (or `-p`): Implementation plan steps (repeat flag for each step) -- `--tags` (or `-g`): Tags (comma-separated) -- `--due`: Due date in YYYY-MM-DD format. No short form -- `--owner` (or `-o`): Owner name -- `--priority`: Priority level, 1 (most urgent) to 5 (least). Unset if omitted. No short form - -Tags are `-g`, not `-t`: `-t` is the title, and passing it twice is an error. Each -plan step needs its own `-p`, since a bare value after one is not a second step. - -```bash -worklane add -t "Implement login" -d "Add user login page" -g login,auth -p "Design UI" -p "Build backend" -p "Write tests" --due 2026-06-01 --owner "ilya" -``` - -When there's multiple acceptance criteria, add each using a separate `--acceptance` or `-a` flag. -When there's mulitple steps to the implementation plan, add each using a separate `--plan` or `-p` flag. - -```bash -worklane add -t "Implement logic" -a "Acceptance criterium 1" -a "Acceptance criterium 2" -p "Step 1" -p "Step 2" -``` - -### `worklane ls` - -List tickets, optionally filtered by status. - -**Valid statuses:** `backlog`, `committed`, `reviewing`, `done` - -``` -worklane ls # List all tickets -worklane ls backlog # List tickets in backlog -worklane ls done # List completed tickets -worklane ls --priority 1 # Only the most urgent, any status -worklane ls backlog --priority 2 # Composes with the status filter -``` - -Tickets are listed priority first, then by title. Tickets with no priority sort last. - -### `worklane show` - -Show the full details of a single ticket by UUID or title. - -``` -worklane show "ticket title or uuid" -``` - -### `worklane mv` - -Move a ticket between statuses. - -**Positional arguments:** -- ``: Ticket UUID prefix (4+ characters) or title - -**Required options:** -- `--status `: Target status (`backlog`, `committed`, `reviewing`, `done`) - -**Options:** -- `-f`: Force move (allows skipping stages and backward moves) - -**Default behavior:** Only allows forward moves, one stage at a time (`backlog` -> `committed` -> `reviewing` -> `done`). - -Examples: - -```bash -worklane mv ticket-id --status committed # Move forward one stage -worklane mv ticket-title --status reviewing -f # Force skip stages -worklane mv a1b2c3d4 --status committed # Move by UUID prefix -worklane mv "My Ticket" --status done -f # Move by title with force -``` - -### `worklane set` - -Replace fields on an existing ticket. Only the fields given are touched; ticked -criteria and handwritten sections are left alone. At least one field is required. - -**Positional arguments:** -- ``: Ticket UUID prefix (4+ characters) or title - -**Options:** `--title`, `--description` (or `-d`), `--acceptance` (or `-a`), `--plan` -(or `-p`), `--tags` (or `-g`), `--due`, `--priority` - -Owner is not settable here, and neither is status: `chown` owns owner and `mv` owns -status. Changing the title renames the file, keeping the UUID. - -```bash -worklane set a1b2c3d4 --priority 1 -worklane set a1b2c3d4 --title "A clearer title" --due 2026-12-31 -worklane set a1b2c3d4 -a "First criterium" -a "Second criterium" -``` - -### `worklane append` - -Add to a section without replacing what is there. The description gains a new -paragraph; criteria and steps go on the end of their lists, steps numbered on from -the last. At least one section is required. - -**Positional arguments:** -- ``: Ticket UUID prefix (4+ characters) or title - -**Options:** `--description` (or `-d`), `--acceptance` (or `-a`), `--plan` (or `-p`) - -```bash -worklane append a1b2c3d4 -d "A paragraph amending the description." -worklane append a1b2c3d4 -a "One more criterium" -worklane append a1b2c3d4 -p "A later step" -``` - -### `worklane chown` - -Set the owner of a ticket. The only command that writes the Owner field: `set` does -not offer it. - -**Positional arguments:** -- ``: The new owner. Free text, checked against nothing -- ``: Ticket UUID prefix (4+ characters) or title - -The user comes first and the ticket second, after Unix `chown`. That is the one -command here that does not start with the ticket, so mind the order: swap the two and -the call fails, because the username has to resolve as a ticket. An owner set to the -value it already holds is reported unchanged and nothing is written. - -```bash -worklane chown alice a1b2c3d4 -worklane chown "Ansho Rei" "A clearer title" -``` - -### `worklane check` and `worklane uncheck` - -Tick or untick a single acceptance criterion. Every other criterion keeps its state, -and handwritten lines in the section are left alone. - -**Positional arguments:** -- ``: Ticket UUID prefix (4+ characters) or title -- `[criterion]`: The number as shown by `worklane show`, or a substring of its text - -Omit the criterion and the numbered criteria are listed and the number asked for. With -no terminal, as when driving the CLI from a tool, the same list comes back as an error -instead, so re-run with the number. A substring matching more than one criterion is an -error listing the matches with their real numbers. - -```bash -worklane check a1b2c3d4 2 -worklane check a1b2c3d4 "renames the file" -worklane uncheck a1b2c3d4 2 -``` - -### `worklane comment` - -Add a comment to a ticket. - -**Positional arguments:** -- ``: Ticket UUID prefix (4+ characters) or title -- ``: Comment text - -Comments are stored as timestamped markdown files in `.worklane/comments//` and include the git author and timestamp. - -Examples: - -```bash -worklane comment ticket-id "Reviewed, looks good" -worklane comment "My Ticket" "Needs changes to the UI" -worklane comment a1b2c3d4 "LGTM, approved" -``` - -## Working a ticket - -Move the ticket as you work it, not afterwards. The board should say what is happening -now, not only what already landed. - -1. `worklane show ` to read it -2. **`worklane mv --status committed` before writing any code.** This is what marks - the ticket as being worked on, so it belongs at the start -3. Do the work. `worklane check ` as each criterion is met -4. `worklane comment ` with anything worth recording: a decision, a rejected - acceptance criterion, something the ticket got wrong -5. **`worklane mv --status reviewing` once it is done and the tests pass** - -Only one stage forward is allowed at a time, so a ticket left in `backlog` until the end -cannot go straight to `reviewing`. It has to be walked through `committed` anyway, which -makes moving it up front the same two commands in a more useful order. - -## Commands - -- `worklane add` creates tickets with all relevant details -- `worklane ls [status]` views tickets by status -- `worklane show ` views full ticket details -- `worklane mv --status ` moves tickets through the workflow -- `worklane set ` corrects a field, `worklane append ` adds to a section -- `worklane check ` ticks a criterion as it is met -- `worklane comment ` adds notes to tickets diff --git a/AGENTS.md b/AGENTS.md index c831ec3..9de27f0 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -327,6 +327,7 @@ and this file is for what someone changing worklane's own code needs. ### Shipping the Agent Assets - The skill is embedded with `include_str!` from `assets/SKILL.md`, not copied by an install script. `cargo install` places binaries and nothing else, so an installed document that is not in the binary is a document that drifts from it +- **`assets/SKILL.md` is the only worklane skill document in this repo, and nothing may reintroduce a second.** There was one: `.opencode/skill/worklane-kanban-skill/SKILL.md`, 223 lines of the same document that nothing shipped and no test checked, and it drifted exactly as far as a copy nobody reads does. Its frontmatter still called the skill `worklane_kanban`, its examples still used short flags the CLI had stopped accepting, and it knew nothing about `relate`, `campaign`, `chown`, `check` or the four-status flow. It was **not** inert while it existed: `opencode debug skill` listed it, so an agent working in this repo saw two worklane skills and could load either. Deleted by b2c5531. A copy under `.opencode/`, in a second assets file, or in the README is the same mistake; the document has one home and `install-skill` is how it travels - **One install path serves both agents:** `~/.claude/skills/worklane/SKILL.md`. Claude Code reads it, and opencode loads that directory as an external skill source alongside its own `~/.config/opencode/skill/`. Verified against opencode 1.15.10, whose built-in `customize-opencode` skill documents the table and whose `opencode debug skill` lists what it found there. Do not add the second path: it is two copies of one document, free to drift, for no gain - `Asset` carries the content, the path under its root and the word used in messages, so `install-tool` adds an entry and its own root rather than a second copy of the compare-and-refuse logic. That is why the module is `install.rs` and not `skill.rs` - `install()` takes the root as an argument. That is what lets the tests install into a temp directory instead of the home of whoever runs the suite, and the integration test redirects `HOME` for the same reason diff --git a/Cargo.lock b/Cargo.lock index c539649..0e1ec57 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1503,7 +1503,7 @@ dependencies = [ [[package]] name = "worklane" -version = "0.23.1" +version = "0.24.0" dependencies = [ "anyhow", "assert_cmd", diff --git a/Cargo.toml b/Cargo.toml index dab08f2..08eca70 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "worklane" -version = "0.23.1" +version = "0.24.0" edition = "2024" [dependencies]