test-all
Run git-test on every local branch that contains upstream, fix failures in a subagent that folds each fix into the breaking commit, and loop until all commits pass. Use when asked to run or fix test-all.
motlin · 已有静态检查记录
安装与使用
运行命令前先阅读来源与依赖说明。复制命令不会自动安装或执行。
npx skills add motlin/claude-code-plugins --skill test-all技能说明
name: test-all description: Run git-test on every local branch that contains upstream, fix failures in a subagent that folds each fix into the breaking commit, and loop until all commits pass. Use when asked to run or fix test-all.
Test All
Resolve <plugin-root> first: in Claude Code use ${CLAUDE_PLUGIN_ROOT}; in Codex use the plugin root that contains this skills/test-all/SKILL.md file.
Run with a timeout of at least 30 minutes:
<plugin-root>/scripts/test-all
The script runs <plugin-root>/scripts/test-branch on every local branch that contains ${UPSTREAM_REMOTE:-upstream}/${UPSTREAM_BRANCH:-main}. That writes the branch name to JUSTFILE_BRANCH and runs git test run --retest --verbose --verbose over the branch's commits. With the default FAIL_FAST=false it continues past failures, so read the output for failed branches instead of trusting the exit code; FAIL_FAST=true stops at the first failure. A failure leaves HEAD detached at the failing commit.
When a branch fails, spawn a subagent to repair it, naming the failing branch. Direct it to, in order:
- Fix the failure following the
build:precommitskill. - Commit the fix with
git commit --fixup <sha>targeting the commit that broke the build, following thegit:commitskill. - Replay the branch onto the fixup commit:
git replay --onto HEAD HEAD^..<branch>. - Autosquash non-interactively:
GIT_SEQUENCE_EDITOR=true git rebase --autosquash ${UPSTREAM_REMOTE:-upstream}/${UPSTREAM_BRANCH:-main}. - Resolve rebase conflicts with the
git:conflictsskill.
Don't fix, commit, or rebase in the main thread: fixes made on git-test's detached HEAD without that replay are stranded off the branch. Then rerun <plugin-root>/scripts/test-all, which resumes where it left off, and repeat until everything passes.
Never run git test forget-results; the cache lets the script skip already-passing commits.