Skip to main content

squash-commits

Reorganize messy branch commits into a small set of logical, meaningful commits without changing any content. Drops merge-from-main commits. Safe: creates a backup branch first.

설치로 이동

소스 정보

저장소
pipecat-ai/pipecat
최근 소스 활동
2026년 5월 20일 13:29
감지된 SKILL.md 언어
영어
스타
15,927
포크
2,764

설치 방법

기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.

소스 파일 검토

설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.

SKILL.md 표시 중

SKILL.md
소스 지침 · 읽기 전용 미리보기
name
squash-commits
description
Reorganize messy branch commits into a small set of logical, meaningful commits without changing any content. Drops merge-from-main commits. Safe: creates a backup branch first.
Reorganize the commits on the current branch into a small number of logical commits. Do NOT change any file content — only the commit structure changes. ## Instructions ### 1. Safety check ```bash git status --short ``` If there are uncommitted changes, stop and tell the user to commit or stash them first. ### 2. Inspect the branch ```bash git log main..HEAD --oneline git diff main..HEAD --name-only ``` List every file changed vs `main` and every commit on the branch (excluding merge commits from main). ### 3. Create a backup branch ```bash git branch backup/<current-branch-name> ``` Tell the user the backup exists so they can recover if needed. ### 4. Soft-reset to main and unstage everything ```bash git reset --soft main git restore --staged . ``` All branch changes are now in the working tree, unstaged. No content has changed. ### 5. Plan the logical groups Read the changed files and the original commit messages to understand what the work covers. Group related files into logical commits. Typical groups: - Core feature or fix (new source files + modified core files) - Secondary features or fixes (each as its own commit if distinct) - Refactoring or renames - Tests - Changelogs / docs Use the changelog files (if any) as a strong hint — each changelog entry often maps to one commit. Present the proposed grouping to the user and ask for confirmation before committing. ### 6. Commit in logical groups For each group, stage only the relevant files and commit with a clear message following the project's conventions: ```bash git add <file1> <file2> ... git commit -m "..." ``` Use conventional commit prefixes if the project uses them (`feat:`, `fix:`, `refactor:`, `test:`, `chore:`). ### 7. Verify ```bash git log main..HEAD --oneline git diff main..HEAD --name-only git status --short ``` Confirm: - Commit count is small and each message is meaningful - The set of changed files vs `main` is identical to before - Working tree is clean ### 8. Remind about force-push The branch history has been rewritten. Tell the user they will need to `git push --force-with-lease` when they are ready to update the remote. Do NOT push automatically. ## Rules - Never change file contents. If you find yourself editing a file, stop. - Never skip the backup branch step. - Never force-push without explicit user instruction. - If any step fails or the result looks wrong, tell the user and suggest restoring from the backup: `git reset --hard backup/<branch-name>`.
GitHub에서 보기