smithery/neversight

clean-history

Reimplement the current branch on a new branch with a clean, narrative-quality git commit history suitable for reviewer comprehension. Use when the user wants to clean up messy commit history before opening a PR.

Installation

$ npx skills add smithery/neversight --skill clean-history

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from smithery/neversight · top by installs.

npx skills add smithery/neversight

Browse all from smithery/neversight

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Skill metadata

Parsed from SKILL.md frontmatter.

Allowed toolsBash(git:*), Bash(gh pr create:*)
Declared agents claude-code

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 3,140 B
  • docs SUMMARY.md 233 B

History

  1. First recorded snapshot · 0 installs

SKILL.md

Clean History

Reimplement the current branch on a new branch with a clean, narrative-quality git commit history.

Context

  • Source branch: !git branch --show-current
  • Git status: !git status --short
  • Default branch: !git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's@^refs/remotes/origin/@@' || git config init.defaultBranch || echo main
  • Remote branches: !git branch -r --list 'origin/main' 'origin/master' 2>/dev/null | head -1 | sed 's/.*origin\///'

Task

Reimplement the current branch on a new branch with a clean, narrative-quality git commit history suitable for reviewer comprehension.

New Branch Name: Use $ARGUMENTS if provided, otherwise {source_branch}-clean.

Base Branch: Determine the base branch using this priority:

  1. The "Default branch" from context above (if available)
  2. The first available branch from "Remote branches" (origin/main or origin/master)
  3. Fall back to main if neither is available

Steps

  1. Validate the source branch

- Ensure no uncommitted changes or merge conflicts - Confirm the source branch is not the same as the base branch (error if so) - Run git log {base}..HEAD --oneline to see commits to clean - Run git diff {base}...HEAD --stat to see the full diff - Confirm source branch is up to date with the base branch

  1. Analyze the diff

- Study all changes between source branch and the base branch - Form a clear understanding of the final intended state

  1. Create the clean branch

- Create a new branch off of the base branch using the new branch name

  1. Plan the commit storyline

- Break the implementation into self-contained logical steps - Each step should reflect a stage of development—as if writing a tutorial

  1. Reimplement the work

- Recreate changes in the clean branch, committing step by step - Each commit must: - Introduce a single coherent idea - Include a clear commit message and description - Use git commit --no-verify for all intermediate commits. Pre-commit hooks check tests, types, and imports that may not pass until the full implementation is complete. Do not waste time fixing issues in intermediate commits that will be resolved by later commits.

  1. Verify correctness

- Confirm the final state exactly matches the source branch - Run the final commit without --no-verify to ensure all checks pass

  1. Open a pull request

- Create a PR with a summary of the changes - Include a link to the original branch in the PR description

Rules

  • Never add yourself as an author or contributor
  • Never include "Generated with Claude Code" or "Co-Authored-By" lines in commits
  • The end state of the clean branch must be identical to the source branch