Finishing a Development Branch
obra/superpowers
Walks the last step of a branch: confirm tests pass, detect the git environment, ask how to integrate, carry out your choice and clean up the worktree.
Rebase the current branch onto the latest origin/main before pushing, reviewing, or opening a PR.
$ npx skills add Smana/cloud-native-ref --skill sync-branch -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install Smana/cloud-native-ref sync-branch --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/Smana/cloud-native-ref.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/sync-branch .claude/skills/sync-branch && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "sync-branch" agent skill from https://github.com/Smana/cloud-native-ref/tree/main/.agents/skills/sync-branch into .claude/skills/sync-branch/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sync-branch", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/Smana/cloud-native-ref/tree/main/.agents/skills/sync-branchType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add Smana/cloud-native-ref --skill sync-branch -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install Smana/cloud-native-ref sync-branch --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Smana/cloud-native-ref.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.agents/skills/sync-branch .agents/skills/sync-branch && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "sync-branch" agent skill from https://github.com/Smana/cloud-native-ref/tree/main/.agents/skills/sync-branch into .agents/skills/sync-branch/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sync-branch", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add Smana/cloud-native-ref --skill sync-branch -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install Smana/cloud-native-ref sync-branch --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Smana/cloud-native-ref.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.agents/skills/sync-branch .cursor/skills/sync-branch && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "sync-branch" agent skill from https://github.com/Smana/cloud-native-ref/tree/main/.agents/skills/sync-branch into .cursor/skills/sync-branch/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sync-branch", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/Smana/cloud-native-ref.git --path .agents/skills/sync-branch--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add Smana/cloud-native-ref --skill sync-branch -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install Smana/cloud-native-ref sync-branch --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Smana/cloud-native-ref.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.agents/skills/sync-branch .gemini/skills/sync-branch && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "sync-branch" agent skill from https://github.com/Smana/cloud-native-ref/tree/main/.agents/skills/sync-branch into .gemini/skills/sync-branch/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sync-branch", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install Smana/cloud-native-ref sync-branchInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add Smana/cloud-native-ref --skill sync-branch -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/Smana/cloud-native-ref.git skills-src && mkdir -p .github/skills && cp -r skills-src/.agents/skills/sync-branch .github/skills/sync-branch && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "sync-branch" agent skill from https://github.com/Smana/cloud-native-ref/tree/main/.agents/skills/sync-branch into .github/skills/sync-branch/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sync-branch", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add Smana/cloud-native-ref --skill sync-branch -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install Smana/cloud-native-ref sync-branch --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Smana/cloud-native-ref.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.agents/skills/sync-branch .opencode/skills/sync-branch && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "sync-branch" agent skill from https://github.com/Smana/cloud-native-ref/tree/main/.agents/skills/sync-branch into .opencode/skills/sync-branch/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sync-branch", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
sync-branchRebase the current branch onto the latest origin/main before pushing, reviewing, or opening a PR.
Sync Branch is an agent skill from Smana/cloud-native-ref. Rebase the current branch onto the latest origin/main before pushing, reviewing, or opening a PR. Fetches origin first so the comparison uses the real remote tip, not a stale local ref. Use when the user says "rebase", "sync with main", "is this up to date", "update the branch", before opening or updating a pull request, and whenever a review or a CI result would otherwise be judged against an outdated merge base.
Its SKILL.md is about 970 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts. Compatibility notes: Requires git and a configured origin remote
It sits in Development, covering Git workflow and Pull requests. It works with Git. The repository describes itself as: Opiniated Cloud Native Platform Reference. The licence is Apache-2.0.
4 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit e5ee7e1. It shows what the files ask for, not the result of running them.
Pre-approves these tools, so the agent can use them without asking each time:
Bash(git:*)From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
gitFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Requires git and a configured origin remote
From compatibility in the SKILL.md frontmatter.
Sync Branch loads about 966 tokens when it runs. Until then it costs about 107 tokens; SKILL.md has 452 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from Smana/cloud-native-ref at commit e5ee7e1, republished under its Apache-2.0 licence (© Smana). 452 words, ~966 tokens.
.claude/skills/sync-branch/SKILL.md (or your agent's skills folder).A branch that is behind origin/main produces a diff that no longer describes what will merge.
Reviews read the wrong merge base, CI passes against code nobody will ship, and conflicts surface
at merge time instead of now.
Run this before every review, push and PR — not only when a conflict is suspected.
Stop and report, do not proceed, when any of these hold:
| Condition | Check | Why |
|---|---|---|
| On the base branch itself | git branch --show-current is main | nothing to rebase |
| Uncommitted changes | git status --porcelain is non-empty | a rebase would strand them. Commit first — ship-it does this before calling you |
| Rebase already running | test -d "$(git rev-parse --git-path rebase-merge)", same for rebase-apply | finish or abort it first |
Resolve that third one through git rev-parse --git-path, never as a literal .git/…. In a
worktree .git is a file, not a directory — it holds gitdir: …/.git/worktrees/<name> — so a
literal path can never match and the guard silently passes. This repo mandates a worktree for every
change, which would make the check dead everywhere it matters.
The fetch is the point. Comparing against a local origin/main that was last updated hours ago
reports "up to date" on a branch that is not.
BASE="${BASE:-main}"
git fetch origin "$BASE"
if git merge-base --is-ancestor "origin/$BASE" HEAD; then
echo "up to date with origin/$BASE"
else
echo "behind origin/$BASE by $(git rev-list --count HEAD..origin/$BASE) commit(s)"
fiWhen the branch is already up to date, say so and stop. Do not rebase for the sake of it — a no-op rebase still rewrites committer dates and invalidates anyone's local copy.
git rebase "origin/$BASE"On conflict, resolve one file at a time and preserve intent from both sides:
git status --short | grep '^UU' # conflicted files
# edit, then:
git add <file>
git rebase --continueIf the conflicts are not mechanically resolvable — two branches changed the same behaviour for
different reasons — git rebase --abort and ask. Guessing which side wins silently reverts
someone's work.
Rebasing does not imply pushing. A rebase rewrites history, so publishing it force-pushes a branch someone may have checked out. Do that only when the caller has actually asked to push or to open a PR — not as a side effect of "sync with main" or of a review.
When the push is wanted and the branch already exists on the remote, use --force-with-lease,
never bare --force: it refuses when someone else has pushed since you last fetched, which is the
entire failure it exists to prevent.
git push --force-with-lease origin "$(git branch --show-current)"A branch that has never been pushed needs no force at all — a plain git push -u origin <branch>
belongs to whatever opens the PR.
State the outcome in one line, with the number that backs it:
already up to date with origin/main (a1b2c3d)rebased 4 commits onto origin/main (a1b2c3d), not pushedrebased 4 commits onto origin/main (a1b2c3d), force-pushed with leaserebase aborted — <file> conflicts on <what>, needs a decision© Smana, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .agents/skills/sync-branch of Smana/cloud-native-ref.
Open the folder on GitHubat commit e5ee7e1
Sync Branch next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Sync Branch this skillSmana/cloud-native-ref | 103 | — | ~966 | Automated safety check: Pass | Apache-2.0 | |
| Finishing a Development Branchobra/superpowers | 296k | 5 repos | ~1.9k | Automated safety check: Pass | MIT | |
| Contributor-First PR MergeHKUDS/OpenHarness | 16k | 1 repos | ~847 | Automated safety check: Pass | MIT | |
| Create Pull Requestcline/cline | 70k | 1 repos | ~1.6k | Automated safety check: Pass | Apache-2.0 | |
| Git Branch Namingmakeplane/plane | 61k | — | ~594 | Automated safety check: Pass | AGPL-3.0 | |
| Creating Description For Gh PRredis/jedis | 12k | — | ~838 | Automated safety check: Pass | MIT |
obra/superpowers
Walks the last step of a branch: confirm tests pass, detect the git environment, ask how to integrate, carry out your choice and clean up the worktree.
HKUDS/OpenHarness
Merges external GitHub pull requests while keeping the original author credited, and fixes conflicts after the merge instead of rewriting the contribution.
cline/cline
Opens a GitHub pull request from your current branch with the gh CLI, after reviewing the commits and diff and gathering the details the PR needs.
makeplane/plane
Names a new Git branch with a type prefix, the lowercased work item ID and a short kebab-case description, so the ID can be extracted later from the branch name.
redis/jedis
Generate a clear, concise GitHub PR title and description from the diff between two local git branches, and save it to prDescription.md in the repo root.
makeplane/plane
Opens a pull request for the current branch using the repo's template, a work item ID in the title and a description filled in from the actual diff.
Smana/cloud-native-ref
Run pre-commit validation before committing. An agent skill from Smana/cloud-native-ref.
Smana/cloud-native-ref
Take a finished branch through the full pre-merge pipeline in one pass — rebase onto origin/main, simplify, prune prose, run the repo's validators and cite their output, review the diff, act on…
Smana/cloud-native-ref
Create or update a Pull Request with AI-generated description, mermaid diagram, file walkthrough, and automatic design-doc detection.
Smana/cloud-native-ref
Research patterns, ecosystem tools, and best practices before writing a design.
Smana/cloud-native-ref
Verify that a merged design's success criteria are actually met in the live cluster.
Works with
Categories
Rebase the current branch onto the latest origin/main before pushing, reviewing, or opening a PR. Sync Branch is an agent skill from Smana/cloud-native-ref. Rebase the current branch onto the latest origin/main before pushing, reviewing, or opening a PR.
Sync Branch fits situations like: the user says rebase; is this up to date; update the branch; updating a pull request.
Run `npx skills add Smana/cloud-native-ref --skill sync-branch -a claude-code`. Or copy the skill folder (.agents/skills/sync-branch in Smana/cloud-native-ref) into .claude/skills/sync-branch in your project. Claude Code loads it when a task matches its description.
Run `npx skills add Smana/cloud-native-ref --skill sync-branch -a codex`. Or copy the skill folder (.agents/skills/sync-branch in Smana/cloud-native-ref) into .agents/skills/sync-branch in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Smana/cloud-native-ref --skill sync-branch -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/sync-branch, .gemini/skills/sync-branch, .github/skills/sync-branch and .opencode/skills/sync-branch in your project.
Going by SKILL.md and its folder, Sync Branch needs the command-line tools its instructions call (git). Its frontmatter pre-approves these tools: Bash(git:*). Compatibility (from SKILL.md): Requires git and a configured origin remote.
SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Sync Branch is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 966 tokens (SKILL.md is roughly 3.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Sync Branch: Finishing a Development Branch (obra/superpowers, 296k stars), Contributor-First PR Merge (HKUDS/OpenHarness, 16k stars), Create Pull Request (cline/cline, 70k stars) and Git Branch Naming (makeplane/plane, 61k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
Smana (a GitHub user) maintains it in Smana/cloud-native-ref, which has 103 GitHub stars. The repository holds 6 skills in this directory. The repository was last updated on October 8, 2026.
Source: Smana/cloud-native-ref on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.