latest-rebase
Skill2 starsChanged 4 months agoMITView on GitHub
Use when the user invokes /latest-rebase or says "rebase on latest main". Rebases current branch onto latest remote main.
- Deletes or force-pushes
- Commits and pushes
In this repository17 other files it gives its agents.
- breakdownSkill
- course-correctSkill
- dispatchSkill
- explainSkill
- improve-architectureSkill
- make-pr-liteSkill
- make-prSkill
- pr-babysitSkill
- pr-breakdownSkill
- pr-explainSkill
- pr-makeSkill
- pr-make-till-mergeSkill
- prompt-reviewSkill
- shippedSkill
- to-ddSkill
- to-issuesSkill
- to-prdSkill
The file
We split this skill into the rules it gives an agent
7 rules. About 0 are common, 7 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈7
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 18
If there are unstaged changes, stash them first:
- Distinctive: line 32
Check if commits are ahead of main:
- Distinctive: line 37
If no commits ahead: branch was already merged.
- Distinctive: line 38
If commits ahead: rebase succeeded with work remaining.
- Distinctive: line 42
If rebase fails with conflicts:
- Distinctive: line 44
Ask the user how to proceed (resolve, abort, or skip)
- Distinctive: line 45
Do NOT automatically resolve conflicts
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Latest Rebase
Rebase the current branch onto the latest remote main. Handles stashing, conflict detection, and force-push.
Execution
1. Fetch and rebase
git fetch origin mainIf there are unstaged changes, stash them first:
git stash
git rebase origin/main
git stash popOtherwise:
git rebase origin/main2. Check result
Check if commits are ahead of main:
git log origin/main..HEAD --oneline- If no commits ahead: branch was already merged. Switch to main, pull, delete branch locally and remotely. Run validate and install.
- If commits ahead: rebase succeeded with work remaining. Ask if the user wants to force-push (
git push --force-with-lease).
3. If rebase had conflicts
If rebase fails with conflicts:
- Show which files have conflicts
- Ask the user how to proceed (resolve, abort, or skip)
- Do NOT automatically resolve conflicts
4. Validate and install
./validate.sh
./install.sh --non-interactive --allCommon Mistakes
| Mistake | Fix |
| Force-pushing without asking | Always ask before --force-with-lease |
| Auto-resolving conflicts | Show conflicts and ask the user |
| Forgetting to validate after rebase | ALWAYS run validate and install |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

