From f3075ae01e9483f7f3e833e1380e919c0da84796 Mon Sep 17 00:00:00 2001 From: Defame1297 Date: Sun, 6 Dec 2026 18:16:28 +0000 Subject: [PATCH] fix(plugins): mark bare commands with rtk-bare: instead of citing ADR-0023 Every deliberately bare git command in git and delivery skill content now carries `rtk-bare: ` on its own line, and the delivery-verify prose explains the bare command without an ADR citation. The git README names the new marker. Bumps metadata.version of delivery-test-first, delivery-verify, git-remotes, git-history and git-worktrees. Refs: #177 Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_014uGZTNugst7K9Bd2FTR4Mi --- .../.apm/skills/delivery-test-first/SKILL.md | 4 ++-- .../.apm/skills/delivery-verify/SKILL.md | 2 +- .../references/already-reverted.md | 4 ++-- .../delivery-verify/references/attribution.md | 4 ++-- .../references/post-merge-ci.md | 4 ++-- plugins/git/.apm/skills/git-history/SKILL.md | 2 +- .../git-history/references/git-log-format.md | 20 +++++++++---------- plugins/git/.apm/skills/git-remotes/SKILL.md | 2 +- .../skills/git-remotes/references/push.md | 4 ++-- .../git/.apm/skills/git-worktrees/SKILL.md | 4 ++-- plugins/git/README.md | 2 +- 11 files changed, 26 insertions(+), 26 deletions(-) diff --git a/plugins/delivery/.apm/skills/delivery-test-first/SKILL.md b/plugins/delivery/.apm/skills/delivery-test-first/SKILL.md index fecc3f5..1fe29e0 100644 --- a/plugins/delivery/.apm/skills/delivery-test-first/SKILL.md +++ b/plugins/delivery/.apm/skills/delivery-test-first/SKILL.md @@ -9,7 +9,7 @@ compatibility: Requires git with push access to the work branch, and a consuming allowed-tools: Read Write Edit Bash metadata: category: delivery - version: "0.2.0" + version: "0.2.1" --- ## Gotchas @@ -58,7 +58,7 @@ Read only the matched flow's reference — each is self-contained. Stage only files under the test paths, then check the staged set before committing: ```bash -git diff --cached --name-only # bare: the path list is parsed (ADR-0023) +git diff --cached --name-only # rtk-bare: the path list is parsed ``` Any path outside the test paths → unstage it. Commit exactly once per run, with a Conventional diff --git a/plugins/delivery/.apm/skills/delivery-verify/SKILL.md b/plugins/delivery/.apm/skills/delivery-verify/SKILL.md index 4f17f20..b1a8452 100644 --- a/plugins/delivery/.apm/skills/delivery-verify/SKILL.md +++ b/plugins/delivery/.apm/skills/delivery-verify/SKILL.md @@ -9,7 +9,7 @@ compatibility: Requires git, a Gitea forge with Actions reached through the Gite allowed-tools: Read Bash mcp__gitea__pull_request_read mcp__gitea__list_pull_requests mcp__gitea__commit_read mcp__gitea__actions_run_read mcp__gitea__get_file_contents metadata: category: delivery - version: "0.1.0" + version: "0.1.1" --- ## Gotchas diff --git a/plugins/delivery/.apm/skills/delivery-verify/references/already-reverted.md b/plugins/delivery/.apm/skills/delivery-verify/references/already-reverted.md index 74776ad..297e96f 100644 --- a/plugins/delivery/.apm/skills/delivery-verify/references/already-reverted.md +++ b/plugins/delivery/.apm/skills/delivery-verify/references/already-reverted.md @@ -13,10 +13,10 @@ in Step 1, before any waiting, and again where `references/apply-wait.md` and the merge commit whose message reverts it, oldest first: ```bash - git log --reverse --format=%H -F --grep='Reverts merge commit ' --grep='This reverts commit ' ..origin/ # ADR-0023: parsed + git log --reverse --format=%H -F --grep='Reverts merge commit ' --grep='This reverts commit ' ..origin/ # rtk-bare: the output is parsed ``` - Bare `git`, per ADR-0023: rtk filters `git log` and this output is parsed. Full 40-character + Bare `git`, not `rtk git`: rtk filters `git log` and this output is parsed. Full 40-character SHA in both patterns. Not `--first-parent`: a revert PR merged with a merge commit puts the revert on the second parent. The first SHA listed is the **revert commit**. diff --git a/plugins/delivery/.apm/skills/delivery-verify/references/attribution.md b/plugins/delivery/.apm/skills/delivery-verify/references/attribution.md index 1345fb5..c4bc513 100644 --- a/plugins/delivery/.apm/skills/delivery-verify/references/attribution.md +++ b/plugins/delivery/.apm/skills/delivery-verify/references/attribution.md @@ -36,10 +36,10 @@ Otherwise tied when both hold: ancestor carrying a status with the same name: ```bash - git log --first-parent --format=%H -n 50 ^1 # ADR-0023: parsed + git log --first-parent --format=%H -n 50 ^1 # rtk-bare: the output is parsed ``` - Bare `git`, per ADR-0023: rtk filters `git log` and this output is parsed. Read each SHA's + Bare `git`, not `rtk git`: rtk filters `git log` and this output is parsed. Read each SHA's statuses with `mcp__gitea__commit_read` `get_status`, newest first. A `skipped` status ran nothing, so pass over it, but only when every row of its workflow (the status name's prefix before ` / `) on that commit is `success` or `skipped`; otherwise a failure there may have diff --git a/plugins/delivery/.apm/skills/delivery-verify/references/post-merge-ci.md b/plugins/delivery/.apm/skills/delivery-verify/references/post-merge-ci.md index 9935c89..81a9b04 100644 --- a/plugins/delivery/.apm/skills/delivery-verify/references/post-merge-ci.md +++ b/plugins/delivery/.apm/skills/delivery-verify/references/post-merge-ci.md @@ -32,10 +32,10 @@ For each such workflow, run `references/already-reverted.md` again (a revert → the default branch's first-parent commits after the merge commit, oldest first: ```bash -git log --first-parent --reverse --format=%H ..origin/ # ADR-0023: parsed +git log --first-parent --reverse --format=%H ..origin/ # rtk-bare: the output is parsed ``` -Bare `git`, per ADR-0023: rtk filters `git log` and this output is parsed. That check's fetch +Bare `git`, not `rtk git`: rtk filters `git log` and this output is parsed. That check's fetch found no revert, so none of these is at or after one. Read each SHA's statuses with `mcp__gitea__commit_read` `get_status`: diff --git a/plugins/git/.apm/skills/git-history/SKILL.md b/plugins/git/.apm/skills/git-history/SKILL.md index dea78e5..afc4671 100644 --- a/plugins/git/.apm/skills/git-history/SKILL.md +++ b/plugins/git/.apm/skills/git-history/SKILL.md @@ -8,7 +8,7 @@ description: > `git-commits`. Not a Gitea server's history -> `gitea-branches`. metadata: - version: "1.0.3" + version: "1.0.4" category: git source_keys: - git-scm-bisect-docs diff --git a/plugins/git/.apm/skills/git-history/references/git-log-format.md b/plugins/git/.apm/skills/git-history/references/git-log-format.md index 8aa5b2d..1378788 100644 --- a/plugins/git/.apm/skills/git-history/references/git-log-format.md +++ b/plugins/git/.apm/skills/git-history/references/git-log-format.md @@ -166,10 +166,10 @@ line at roughly 72 characters with an ellipsis, on the one query whose whole poi is showing line content. ```bash -git log -L 10,20:file.txt # bare (ADR-0023) -git log -L /start_pattern/,/end_pattern/:file.txt # bare (ADR-0023) -git log -L :myfunction:src/app.c # bare (ADR-0023) -git log -L /init/,+15:config.py # bare (ADR-0023); 15 lines after first /init/ match +git log -L 10,20:file.txt # rtk-bare: rtk truncates diff lines +git log -L /start_pattern/,/end_pattern/:file.txt # rtk-bare: rtk truncates diff lines +git log -L :myfunction:src/app.c # rtk-bare: rtk truncates diff lines +git log -L /init/,+15:config.py # rtk-bare: rtk truncates diff lines; 15 lines after first /init/ match ``` Range formats: @@ -213,8 +213,8 @@ Bare `git`, not `rtk git`: rtk appends a blank line and a `Changes:` trailer, so the output is no longer one record per line. ```bash -git diff --name-only # bare (ADR-0023); only filenames, one per line -git diff --name-status # bare (ADR-0023); status letter + filename per line +git diff --name-only # rtk-bare: rtk adds a trailer; only filenames, one per line +git diff --name-status # rtk-bare: rtk adds a trailer; status letter + filename per line ``` `--name-status` uses the same status letters as `--diff-filter`. @@ -225,10 +225,10 @@ Bare `git`, not `rtk git`: rtk replaces the word-diff with its own diffstat renderer and emits none of the `[-removed-] {+added+}` markers. ```bash -git diff --word-diff # bare (ADR-0023); inline word-level diff, [-removed-] {+added+} markers -git diff --word-diff=color # bare (ADR-0023); color only, no markers -git diff --word-diff=porcelain # bare (ADR-0023); machine-readable: +/- prefixed lines, ~ for newlines -git diff --word-diff-regex= # bare (ADR-0023); define what counts as a "word" +git diff --word-diff # rtk-bare: rtk drops the word-diff; inline word-level diff, [-removed-] {+added+} markers +git diff --word-diff=color # rtk-bare: rtk drops the word-diff; color only, no markers +git diff --word-diff=porcelain # rtk-bare: rtk drops the word-diff; machine-readable: +/- prefixed lines, ~ for newlines +git diff --word-diff-regex= # rtk-bare: rtk drops the word-diff; define what counts as a "word" ``` ### Whitespace Flags diff --git a/plugins/git/.apm/skills/git-remotes/SKILL.md b/plugins/git/.apm/skills/git-remotes/SKILL.md index 9b94ddd..45008f1 100644 --- a/plugins/git/.apm/skills/git-remotes/SKILL.md +++ b/plugins/git/.apm/skills/git-remotes/SKILL.md @@ -10,7 +10,7 @@ description: > Not submodule pointers -> `git-submodules`. metadata: - version: "1.0.4" + version: "1.0.5" category: git source_keys: - git-scm-remote-docs diff --git a/plugins/git/.apm/skills/git-remotes/references/push.md b/plugins/git/.apm/skills/git-remotes/references/push.md index 8bec56e..cb99207 100644 --- a/plugins/git/.apm/skills/git-remotes/references/push.md +++ b/plugins/git/.apm/skills/git-remotes/references/push.md @@ -50,13 +50,13 @@ Two mitigations: # poisoned by an unrelated fetch. # The inner `git config` is bare: its stdout becomes a remote URL, so any # output rewriting would poison the remote silently. -rtk git remote add origin-push $(git config remote.origin.url) # inner bare (ADR-0023) +rtk git remote add origin-push $(git config remote.origin.url) # rtk-bare: inner command; rewritten output would corrupt the URL rtk git push --force-with-lease origin-push # Option 2 — explicit SHA via a local tag, unaffected by tracking-branch state rtk git fetch rtk git tag base master -git rebase -i master # bare, not `rtk` (ADR-0023): interactive sequence editor +git rebase -i master # rtk-bare: interactive sequence editor rtk git push --force-with-lease=master:base master:master ``` diff --git a/plugins/git/.apm/skills/git-worktrees/SKILL.md b/plugins/git/.apm/skills/git-worktrees/SKILL.md index 20414d5..4552ee0 100644 --- a/plugins/git/.apm/skills/git-worktrees/SKILL.md +++ b/plugins/git/.apm/skills/git-worktrees/SKILL.md @@ -8,7 +8,7 @@ description: > Not interactive multi-step git guidance -> `git-workflow`. metadata: - version: "1.0.3" + version: "1.0.4" category: git source_keys: - git-scm-worktree-docs @@ -32,7 +32,7 @@ metadata: | Create a local branch tracking a remote one | `rtk git worktree add --track -b /` — always correct. `git worktree add ` expands to exactly this, but **only** under the conditions in `references/worktrees.md` | | Throwaway experiment, no branch | `rtk git worktree add -d ` — detached HEAD | | **Never** `git worktree add /` | That ref resolves, so the shortcut never fires and you get **a detached HEAD, no branch, no upstream**. Commits there go unreachable once HEAD moves, and `git push` needs an explicit refspec. Use the tracking row above | -| List | `git worktree list -v` to read, or `git worktree list --porcelain -z` to parse — both bare (ADR-0023): rtk re-renders the output and drops the porcelain flags | +| List | `git worktree list -v` to read, or `git worktree list --porcelain -z` to parse — rtk-bare: rtk re-renders the output and drops the porcelain flags | | Lock or unlock | `rtk git worktree lock [--reason ] ` / `rtk git worktree unlock ` | | Move | `rtk git worktree move ` | | Remove | `rtk git worktree remove ` | diff --git a/plugins/git/README.md b/plugins/git/README.md index b6b750d..726d494 100644 --- a/plugins/git/README.md +++ b/plugins/git/README.md @@ -25,7 +25,7 @@ The entry above is unpinned and tracks the remote's default branch. To pin a rel ## Conventions -Skills here run local git commands through the org's `rtk` wrapper. **When a command is prefixed, when it stays bare, and why some executable commands must stay bare are all decided by ADR-0023** (`docs/adr/0023-rtk-prefix-marks-executable-commands-only.md`), which is repo-wide and not specific to this plugin. `check-rtk-prefix` enforces the part of it that is machine-decidable. +Skills here run local git commands through the org's `rtk` wrapper. **When a command is prefixed, when it stays bare, and why some executable commands must stay bare are all decided by ADR-0023** (`docs/adr/0023-rtk-prefix-marks-executable-commands-only.md`), which is repo-wide and not specific to this plugin. `check-rtk-prefix` enforces the part of it that is machine-decidable. A command that must stay bare carries `rtk-bare: ` on its own line, which is the gate's opt-out marker. Installing this plugin without `rtk`? Every prefixed command is a plain `git` invocation with a word in front of it — drop the `rtk ` and it is correct.