/tend-ci-runner:propose-instructionsfrom tend-ci-runner
Proposes durable instructions from maintainer corrections or guidance gaps, determining whether a rule belongs in a repo overlay or upstream bundled skills.
Ships in tend-ci-runner. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Turning a maintainer's correction into durable instructions for future runs. It
lands in one of two places: this repo's own running-tend overlay, which only
sessions here read, or tend's bundled skills upstream at max-sixty/tend,
which every repo tend maintains reads. This skill covers whether the correction
clears the bar, which of the two it lands in, what the text carries, and the
mechanics of proposing it.
/tend-ci-runner:act-in-other-repos before filing an upstream Tend issue./tend-ci-runner:post-to-github and /tend-ci-runner:open-pr before composing and opening a repo-local skill PR./tend-ci-runner:push-commits before pushing that PR.Propose instructions when the evidence identifies a generalizable guidance gap and the expected benefit outweighs the ambiguity, reading cost, and upkeep of the rule. Inspect the guidance loaded at the decision and how it contributed to the outcome. Repeated reports of a lapse do not establish that instructions were missing or wrong; a failure under adequate guidance may need no new rule.
Weigh exposure, consequences, and what will catch the failure in future runs. A failure invisible to CI can warrant an instruction repair without waiting for another incident. Prefer correcting or removing the responsible text to adding reminders beside adequate guidance. Task-specific details and uncertain causal explanations stay in the current investigation.
A maintainer's request to codify a rule establishes their desired policy even
without prior incidents. Non-maintainer feedback can supply evidence, but only
a maintainer authorizes repository preferences — check author_association
before turning one into a durable rule.
Settle the destination before drafting a line, on two questions: would every tend consumer want this rule, and is it ours to state? Mechanics are the first kind — how GitHub behaves, what the harness does, what a session must never do. A judgment about what is worth doing in a repo — the complexity it will spend, the CI time worth saving, how many open PRs is too many — belongs to whoever maintains that repo, and goes in its overlay even where it reads as generic good sense; bundled, it makes every other repo answer to this one's maintainer.
Where the answer to both is yes, the rule belongs in tend's bundled skills, and what the bundled text currently says doesn't change that:
The overlay is for what is true of one repo alone — its branch and landing conventions, its test topology, its trackers and labels, its standing exceptions — and for its maintainer's judgments above. A rule of mechanics goes upstream even when writing it locally would be quicker.
Upstream means an issue on max-sixty/tend, filed per Filing issues in
/tend-ci-runner:act-in-other-repos.
Instructions state the rule a future session acts on: the shape to follow and
the shape to avoid, in a few lines. That holds in a skill, an overlay, or a
project instruction file such as CLAUDE.md, and for text suggested in a
review as much as text you commit. Leave out how the rule came about — the PRs,
issues, and runs that exposed the gap, and the maintainer's wording; the PR
body links that evidence. Cited cases read as the rule's targets and age into
trivia. A decision settled for one site belongs in a comment at that site,
where the next session to edit it will read it.
When a skill's code block needs tested logic or edge-case handling, put it in
a tested script in a scripts/ directory beside the skill, and leave the skill
a one-line invocation with the intent. A prose
recipe gets no shellcheck and no tests; every session re-derives its
correctness.
These steps are for the overlay path. Filing upstream follows
/tend-ci-runner:act-in-other-repos instead.
Complete the current task first. The skill update is always a separate PR.
Check for an existing open PR against the same skill. Dedup by the target file, not by title — title conventions vary per repo:
BOT_LOGIN=$(gh api user --jq '.login')
gh pr list --state open --author "$BOT_LOGIN" --limit 200 --json number,title,headRefName,files \
--jq '.[] | select([.files[].path] | index(".claude/skills/running-tend/SKILL.md"))'
If one is open, add to it instead of opening a second.
Draft the edit per What the text carries, under an appropriate heading. New SKILL.md files start with YAML frontmatter:
---
name: running-tend
description: Project-specific instructions for tend workflows running on this repo.
---
The checkout's .claude/ directory is bind-mounted read-only under
the sandbox (protecting bots from modifying their own skills in place), so
edits to .claude/skills/ files in the working tree fail with Read-only file system. Claude Code's harness adds a second restriction on top of
the read-only mount: Edit, Write, and Bash commands with
.claude/skills/ as a write-target argument are denied regardless of
filesystem permissions
(anthropics/claude-code#37157).
The guard checks argument text, so Write(/home/tend-sandbox/tmp/…) and
Bash(mv $TMPDIR/… SKILL.md) both pass — the second because SKILL.md is a
bare filename inside the cd'd directory.
Do the edit, commit, and push from a git worktree under $TMPDIR, which is
writable and sits outside the harness's .claude/skills/ write-guard.
Tend sets $TMPDIR before the agent starts.
Base the skill branch on the repo's default branch, not HEAD. When
this runs from tend-mention on a PR, the workflow has already done
gh pr checkout so HEAD is the PR branch — basing on it carries that
PR's WIP commits into the skill PR and ships a multi-concern PR that mixes
the skill change with unrelated code. Fetch and base off
origin/<default> instead:
DEFAULT_BRANCH=$(gh repo view --json defaultBranchRef --jq '.defaultBranchRef.name')
git fetch origin "$DEFAULT_BRANCH"
git worktree add "$TMPDIR/skill-fix" -b "skills/<topic>-$GITHUB_RUN_ID" "origin/$DEFAULT_BRANCH"
# Author the new skill file at $TMPDIR/running-tend-new.md.
# Then move it into place from inside the worktree. mkdir -p covers the
# new-skill case where .claude/skills/<name>/ doesn't yet exist in the
# default branch. Both `cd`s stay inside subshells, so the session's own
# cwd never enters the worktree: the last line deletes it, and a session
# standing in it has no working directory for anything after this block.
mkdir -p "$TMPDIR/skill-fix/.claude/skills/running-tend"
( cd "$TMPDIR/skill-fix/.claude/skills/running-tend" && mv "$TMPDIR/running-tend-new.md" SKILL.md )
(
set -e
cd "$TMPDIR/skill-fix"
git add .claude/skills/
git commit -m "skills(running-tend): ..."
git push -u origin skills/<topic>-$GITHUB_RUN_ID
gh pr create --title "..." --body-file "$TMPDIR/pr-body.md" --head skills/<topic>-$GITHUB_RUN_ID
) && git worktree remove "$TMPDIR/skill-fix" --force
Open as a separate PR. Follow the repo's PR title conventions
(conventional commits, Jira prefix, or whatever the repo uses — check
recent merged PRs or CONTRIBUTING.md). The body states the generalized
behavior gap and the outcome the new instructions should produce, then links
the triggering thread as evidence. Do not quote or reconstruct the exchange.
Open and exit — don't merge, don't wait. The PR itself is the review
request; a maintainer lands it (or doesn't) in their own time. Don't post
a separate comment pinging for review, and don't block the session
waiting. This open-and-exit is for skill proposals only; a code fix
follows Complete the task before ending the turn in
/tend-ci-runner:run-tend.
What SKILL.md sets; muted values are Claude Code's defaults
24 skills in this plugin
/act-in-other-reposAct in another repository. Use before filing an issue, commenting, or contributing anywhere other than this repo./check-requester-accessCheck a requester's access tier. Use when a request aims you at someone else's work — close, lock, label, revert, dismiss, push./code-reviewStructured second pass over a diff — correctness and cleanup angles, a verify pass, ranked findings returned to the caller./continue-prContinue an unfinished PR with no human author, including red CI and unresolved findings after a prior response or review./dismiss-approvalDismiss a standing bot approval. Use when you conclude that a PR the bot approved should not merge./fix-a-bugWrite a code fix for a bug. Use before writing any fix, whichever workflow you are running.npx claudepluginhub max-sixty/tend --plugin tend-ci-runnerOther plugins' skills for the same job