@@ -14,7 +14,8 @@ When invoked, route to one mode:
14141 . ** workflow** — branching strategy, conflict resolution, commit history, and
1515 basic Git operations.
16162 . ** commit-message** — conventional commit style, scope, and quality checks.
17- 3 . ** github-toolkit** — any GH PR review comments, check triage, or issue creation.
17+ 3 . ** github-toolkit** — any GH PR review comments, check triage, or issue
18+ creation.
1819
1920If intent is unclear, ask for the mode before applying changes.
2021
@@ -23,25 +24,28 @@ If intent is unclear, ask for the mode before applying changes.
2324Use for task planning, branch hygiene, rebase/merge decisions, conflict
2425resolution, and ` git ` command guidance.
2526
26- - Check [ git-reference.md] ( references/git-reference.md ) for command/reference tables.
27+ - Check [ git-reference.md] ( references/git-reference.md ) for command/reference
28+ tables.
2729- Check [ git-examples.md] ( references/git-examples.md ) for workflow templates.
2830
2931## 2) Commit Message Mode
3032
3133Use for commit message policy and drafting, including commit format choice and
3234scope rules.
3335
34- - Check [ commit-reference.md] ( references/commit-reference.md ) for commit type tables
35- and rules.
36- - Check [ commit-examples.md] ( references/commit-examples.md ) for good/bad examples.
36+ - Check [ commit-reference.md] ( references/commit-reference.md ) for commit type
37+ tables and rules.
38+ - Check [ commit-examples.md] ( references/commit-examples.md ) for good/bad
39+ examples.
3740
3841Core policy:
3942
4043- Match the repository history (` git log ` ) first.
4144- Prefer imperative, short, scoped subjects.
4245- Never emit literal ` \n ` escape sequences in commit message text.
4346 - Forbidden: ` git commit -m "line1\nline2" `
44- - Correct pattern for multi-line bodies: repeat ` -m ` flags or use a heredoc/file input.
47+ - Correct pattern for multi-line bodies: repeat ` -m ` flags or use a
48+ heredoc/file input.
4549
4650 ``` bash
4751 # preferred
@@ -52,10 +56,12 @@ Commit strategy (must enforce):
5256
5357- Before committing, follow local history strategy first:
5458 - prefer ` git commit --amend ` for immediate HEAD corrections,
55- - prefer ` fixup ` + ` --autosquash ` for nearby regressions when history is local-only (unshared/unpushed).
56- - avoid adding tiny follow-up commits when a history edit is the better option.
57- - If a change requires splitting, squashing, or reordering, state the target history
58- shape before running the command.
59+ - prefer ` fixup ` + ` --autosquash ` for nearby regressions when history is
60+ local-only (unshared/unpushed).
61+ - avoid adding tiny follow-up commits when a history edit is the better
62+ option.
63+ - If a change requires splitting, squashing, or reordering, state the target
64+ history shape before running the command.
5965
6066## 2a) Hunk-Level Git Strategy
6167
@@ -66,7 +72,8 @@ Use `git-surgeon` for non-interactive, hunk-level git operations:
6672- undoing or splitting commits by hunk IDs
6773- reordering commits without broad interactive workflows
6874
69- Before using it, read [ references/git-surgeon.md] ( references/git-surgeon.md ) and follow its safety rules.
75+ Before using it, read [ references/git-surgeon.md] ( references/git-surgeon.md ) and
76+ follow its safety rules.
7077
7178## 3) GitHub Extensions
7279
@@ -82,12 +89,13 @@ This keeps Git logic and GitHub workflow logic separate.
8289
8390- For commands that touch shared history or remote state, call out destructive
8491 risk explicitly before running them.
85- - If a recent commit introduced a breaking regression and the commit is local-only,
86- prefer ` fixup ` + ` --autosquash ` (via an interactive rebase) to fold the
87- correction into the originating commit, instead of stacking follow-up commits.
92+ - If a recent commit introduced a breaking regression and the commit is
93+ local-only, prefer ` fixup ` + ` --autosquash ` (via an interactive rebase) to
94+ fold the correction into the originating commit, instead of stacking follow-up
95+ commits.
8896- If the commit has been pushed/shared, avoid history rewrite; use conventional
8997 follow-up commits and/or coordinated PR update flow.
9098- For multi-step changes, default to minimal safe steps and stop at user
9199 confirmation points.
92- - Cross-skill references are intentionally non-duplicative: only ` git ` materials stay
93- in this toolkit.
100+ - Cross-skill references are intentionally non-duplicative: only ` git ` materials
101+ stay in this toolkit.
0 commit comments