branch-finishing

branch-finishing is a cursor rule for Cursor from sordi-ai/skill-everything. It costs 27 tokens per session (697 once invoked), scanned A, original, MIT.

A set of rules for finishing a Git feature branch before and after merging it into the main codebase.

In plain words
What is it for?
Use it to rebase, resolve conflicts, run checks, review the final diff, clean up commits, and close linked issues when a branch is merged.
Why use it?
It reduces the chance of merging regressions, unresolved conflicts, debug code, or messy commit history. It also helps avoid leaving outdated local branches and files behind.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use it to rebase, resolve conflicts, run checks, review the final diff, clean up commits, and close linked issues when a branch is merged.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/sordi-ai/skill-everything/branch-finishing
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/sordi-ai/skill-everything

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for branch-finishing

README.md
[![agentmods](https://agentmods.dev/badge/rules/sordi-ai/skill-everything/branch-finishing/github.svg)](https://agentmods.dev/rules/sordi-ai/skill-everything/branch-finishing)
Your own site
<a href="https://agentmods.dev/rules/sordi-ai/skill-everything/branch-finishing"><img src="https://agentmods.dev/badge/rules/sordi-ai/skill-everything/branch-finishing/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for branch-finishing

Your own site · 80×15
<a href="https://agentmods.dev/rules/sordi-ai/skill-everything/branch-finishing"><img src="https://agentmods.dev/badge/rules/sordi-ai/skill-everything/branch-finishing.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 27 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 697 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00027 $0.00697
Opus 5 $0.00014 $0.00349
Sonnet 5 $0.00005 $0.00139
Haiku 4.5 $0.00003 $0.00070

Measured 9d ago against content hash 9d656dce2aa0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

branch-finishing scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/branch-finishing.mdc · 49 lines

How it starts

The opening of the file, as written. The whole thing — 49 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Sub-Skill: Branch Finishing

Purpose: Ensures every feature branch is cleanly rebased, reviewed, and merged without introducing regressions or leaving stale local state behind.


Rules

Pre-Merge Preparation

  1. Rebase before merge. Always rebase onto the target branch immediately before requesting merge to catch regressions introduced since the branch was cut. Reference: ERR-2026-024
  2. Resolve conflicts locally. Before pushing a rebase, resolve every conflict locally and run the full test suite; never push a branch with unresolved markers.
  3. CI green before review. Ensure all CI checks pass on the latest push before requesting a human review; do not ask reviewers to look at a red branch.
  4. Self-review diff. Before opening a PR, run git diff main...HEAD and read every changed line; catch debug prints, commented-out code, and accidental file inclusions yourself first.

Commit Hygiene

  1. Squash fixup commits. Before merge, squash or fixup any wip:, fixup!, or tmp: commits so the branch history is clean; use git rebase -i to consolidate.
  2. Issue closing keywords. Use Closes #NNN or Fixes #NNN in the PR body so the linked issue auto-closes on merge; never leave issues open manually after a successful merge.
  3. Changelog update. After any user-visible change, add an entry to CHANGELOG.md (or the project's equivalent) before marking the PR ready for review.
  4. Version bump. If the project uses semantic versioning, bump the version in the appropriate manifest file as part of the branch before merge, not as a follow-up commit.

Draft → Ready Transition

  1. Draft until CI passes. Keep the PR in draft state until all CI checks are green and the self-review is complete; convert to ready-for-review only when the branch is genuinely merge-ready.
  2. Remove draft status explicitly. Use gh pr ready <number> to convert from draft; do not rely on reviewers noticing a draft PR that was silently updated.

Read the full file on GitHub · 49 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 49 lines · 27 tokens per session scan A 9d656dce2aa0

Subscribe to this mod's changes

branch-finishing is a cursor rule published in the GitHub repository sordi-ai/skill-everything (20 stars, last pushed 3mo ago), licensed MIT. It adds 27 tokens to every session and 697 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other cursor rules, from other repositories

release-notes

Generate changelog entries and GitHub releases from git history. Categorizes commits into features, fixes, breaking changes, and docs. Supports conventional commits, PR-based grouping, and semantic versioning. Creates formatted CHANGELOG.md entries and GitHub releases.

thatrebeccarae/claude-marketing · 50 tokens

github

GitHub repository operations: PRs, issues, releases, branch protection, CODEOWNERS, Dependabot, and repo settings audits. Use when user says 'review my PR', 'create a release', 'cut a release', 'tag a release', 'set up branch protection', 'add CODEOWNERS', 'audit repo settings', 'is Dependabot configured', or asks…

anmolnagpal/devops-skills · 0 tokens

gitops

Argo CD and Flux review and scaffolding: mutable source refs, AppProject wildcard grants, unguarded auto-prune, sync waves and dependency ordering, selfHeal drift enforcement, and per-environment separation. Use when user says 'review my argocd', 'review my Application', 'check my flux config', 'set up gitops', 'why…

anmolnagpal/devops-skills · 0 tokens

safe-push

Pre-push hygiene check for GitHub repositories. Scans for PII, secrets, and sensitive data before pushing. Audits commit messages, enforces repo-specific blocklists, and rate-limits pushes to avoid GitHub abuse detection. Use before any git push, especially to public repos.

thatrebeccarae/claude-marketing · 59 tokens

ponytail

Ponytail, lazy senior dev mode. Always pick the simplest solution that works.

DietrichGebert/ponytail · 576 tokens

angular-20

This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.

angular/angular · 0 tokens