一键导入
force-push-downstream
// Force-push a branch and all its downstream branches to origin. Auto-detects the downstream tree and skips branches already up-to-date. Triggers on: force push downstream, push chain, push all branches.
// Force-push a branch and all its downstream branches to origin. Auto-detects the downstream tree and skips branches already up-to-date. Triggers on: force push downstream, push chain, push all branches.
Add a new best practice to the appropriate doc. Checks for duplicates, assigns stable IDs, creates new category docs if needed. Triggers on: add best practice, new best practice, add bp, new bp.
"Create an uplift PR that cherry-picks merged PRs from a contributor into a target branch (beta or release). Defaults to broad eligibility; the scope can be narrowed via a free-form description (e.g. 'only automated test and crash fixes'). Triggers on: /uplift, create uplift, uplift PRs."
Review PRs in the configured PR repository for best practices violations. Supports single PR (#12345), state filter (open/closed/all), and auto mode for cron. Triggers on: review prs, review recent prs, /review-prs, check prs for best practices.
Run all preflight checks (format, gn_check, presubmit, build, tests) to make sure the current work is ready for review.
Check if a failing test is a known upstream flake in Chromium's LUCI Analysis database. Provides flakiness statistics, verdict, and recommendation for filter file decisions. Triggers on: check upstream flake, is this test flaky upstream, check luci flakiness, upstream flake check.
Delete local branches whose PRs have been merged upstream. Checks GitHub PR status for each branch. Triggers on: clean branches, delete merged branches, prune branches, branch cleanup.
| name | force-push-downstream |
| description | Force-push a branch and all its downstream branches to origin. Auto-detects the downstream tree and skips branches already up-to-date. Triggers on: force push downstream, push chain, push all branches. |
| argument-hint | [starting-branch] |
| disable-model-invocation | true |
Force-push a branch and all its downstream branches to their respective remotes. Skips branches whose local and remote tips already match.
starting-branch (optional) — The branch to start from. Defaults to the
current branch if not specified.Examples:
/force-push-downstream — push current branch + all downstream/force-push-downstream candle-service-webui — push from that branch downgit branch --show-currentgit status --shortIf an argument was provided, use it as the starting branch. Otherwise use the current branch.
git branch --show-current
Run the detect-chain script (shared with rebase-downstream) to find all downstream branches:
bash .claude/skills/rebase-downstream/detect-chain.sh <starting-branch>
The push list is: the starting branch itself, followed by every downstream branch in tree order (from detect-chain output).
Display the branches that will be pushed:
Force push plan:
candle-service-background-webcontents
→ background-webcontents-timer
→ candle-service-webui
→ candle-service-model-loading
→ brave-history-embeddings
→ local-ai-internals
For each branch, check if it is already up-to-date with origin:
# Get local and remote SHAs
local_sha=$(git rev-parse <branch>)
remote_sha=$(git rev-parse origin/<branch> 2>/dev/null || echo "none")
If local_sha == remote_sha, mark as (up-to-date, will skip). If the remote
branch doesn't exist, mark as (new, will push). Otherwise mark as
(diverged, will force-push).
Ask the user to confirm before pushing.
For each branch in the push list:
Skip if up-to-date: If local SHA matches origin SHA, print skip message and move on.
Force push:
git push --force-with-lease origin <branch>
Use --force-with-lease for safety — it fails if someone else pushed to the
remote since our last fetch, preventing accidental overwrites of others'
work.
If the remote branch doesn't exist (first push), use:
git push -u origin <branch>
Report result: Print success/failure for each branch.
After all pushes complete, show a summary:
Force push results:
✓ candle-service-background-webcontents (pushed)
- background-webcontents-timer (skipped, up-to-date)
✓ candle-service-webui (pushed)
✓ candle-service-model-loading (pushed)
✓ brave-history-embeddings (pushed, new)
✗ local-ai-internals (failed: ...)
--force-with-lease instead of --force for safety