agentsclimarketplace

Git workflow

Skill kreek/consult/plugin/skills/git-workflow

Engineering quality focused skills for AI coding agents that keep humans in the loop.

Install
npx -y skills add kreek/consult --skill git-workflow

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Use for branches, history edits, conflicts, rebases, recovery, force-push, and gh.

SKILL.md

5.9 KB, ~1.4k tokens by cl100k_base, as published. Nobody here has run it

Git Workflow

Iron Law

NEVER REWRITE SHARED HISTORY OR SKIP RECOVERY.

Git history is a review, bisect, revert, and release surface. Keep it recoverable, scoped, and honest.

When to Use

  • Rebases, merge conflicts, bisects, reflog recovery, branch cleanup, PR history repair, or force-push decisions.

When NOT to Use

  • Staging reviewed files, splitting commit groups, writing commit messages, or committing approved work. Use commit.
  • Reviewing implementation correctness; use code-review.
  • Refactor planning; use refactoring.
  • CI failure triage; use the relevant CI/GitHub workflow.

Core Ideas

  1. Inspect before mutation. Start with status, branch/upstream, staged and unstaged diff stats, and recent log. Expand only when risk appears.
  2. Prefer --force-with-lease --force-if-includes over bare force when a solo-branch rewrite is genuinely needed.
  3. Preserve a recovery point (tag, named branch, or noted reflog entry) before any risky operation.
  4. Resolve conflicts by preserving intent from both sides, then run the relevant checks.
  5. Test hook policy, not hook wrappers. Tiny hooks that only exec a repo script don't need dedicated tests; test the script when it selects commands, blocks branches, routes staged files, or handles failures.
  6. At the start of a feature or bug fix, ask the user once: create or switch to a topic branch in the current checkout. On a topic branch with distinct new work, ask once between continue here or branch off main. Don't re-prompt during the same piece of work.
  7. Ask before any GitHub CLI command. gh can make network calls and use the user's authenticated account. Get explicit permission before running any gh command, including read-only commands such as gh pr view, gh pr diff, or gh run view.
  8. Humans approve PR and issue text before it is published. Titles and descriptions for gh pr create, gh pr edit, gh issue create, and gh issue edit are author-facing content the user owns. Draft the title and body locally, show them, and get explicit approval of that exact text before any gh command creates or updates the PR or issue. Do not let gh open an editor or send unreviewed body text.

Workflow

  1. Read one compact preflight: status, branch/upstream, staged and unstaged diff stats, and recent log. Stop on unexpected state.
  2. Expand inspection only when risk appears or the operation requires it: merge/rebase state, conflict markers, full diffs, upstream divergence, or recovery points.
  3. Detect hazards: conflicts, secrets, generated churn, unrelated staged work, shared history rewrites, or in-flight work that needs isolation.
  4. For history operations, name the recovery point and whether the branch is local/solo/shared before rewriting, deleting, or force-pushing.
  5. Before GitHub CLI use, ask for permission for the exact gh command or command class needed. Do not treat read-only intent as permission.
  6. When a gh command would create or update a PR or issue, draft the title and description locally, get the user's approval of that text, then run the command with the approved title and body. Do not rely on gh opening an editor or sending unreviewed text.
  7. Execute the smallest safe operation. Verify log/range-diff, status, file membership, and relevant tests or repro commands.

Verification

  • Final status is known and scoped: tree clean or explicitly deferred, no files staged outside the approved group, no unresolved merge/rebase state or conflict markers.
  • Rewritten history was local/solo or explicitly approved; force pushes used lease/inclusion protection.
  • range-diff or log inspection confirms intended commits remain; a reflog/recovery point is available for rollback.
  • Hook tests, when present, cover policy-bearing scripts rather than trivial wrapper files.
  • At the start of work, the user picked a topic branch in the current checkout. The menu did not re-fire during continued work on the same branch, and new work wasn't silently stacked on unrelated branch work.
  • No gh command was run without explicit user permission for that command or command class.
  • PR and issue titles and descriptions were drafted and approved by the user before any gh command created or updated them.

Tripwires

TriggerDo this insteadFalse alarm
"Force push should fix it"Verify the branch is local/solo or approved, then use lease/inclusion protection.Disposable local-only branch with no remote.
"Rewrite this shared branch"Stop and ask for explicit approval plus a recovery point.The branch is confirmed local and unpublished.
"Resolve conflict by taking ours/theirs"Preserve intent from both sides, then run relevant checks.Generated file regenerated after source conflict is resolved.
"Read-only gh is harmless"Ask before any gh command because it uses network and auth.The user already approved that exact command class.
"Just open the PR with a quick title"Draft the title and body, get the user's approval, then run gh pr create/gh issue create.The user already approved that exact title and body.

Handoffs

  • Use commit for staging reviewed work, splitting commit groups, writing commit messages, or committing approved changes.
  • Use refactoring when separating structural and behavioral changes requires code changes.
  • Use release when the working tree includes a version manifest bump, CHANGELOG entry, deprecation, or release tag.
  • Use debugging before bisecting if the failure is not reproducible.
  • Respect Codex/user sandbox approval requirements; this skill does not bypass permission gates.

Gives 0 of the 12 instructions most pr commit review skills give in ~1.4k tokens

Counted across 888 of the 1,342 authors here whose files we hold, read 2026-08-07

  • use conventional commits formatin 127 of 888, across 115 files
  • keep subject line under 72 charactersin 62 of 888, across 48 files
  • delete branches after mergein 51 of 888, across 38 files
  • use imperative mood in subject linein 51 of 888, across 42 files
  • use imperative mood in commit messagesin 44 of 888
  • verify directory is ignored before creating worktreein 43 of 888, across 12 files
  • generate a conventional commit messagein 43 of 888
  • add unignored worktree directories to gitignorein 42 of 888, across 10 files
  • make atomic commitsin 39 of 888, across 27 files
  • run tests before committingin 36 of 888, across 25 files
  • verify clean test baselinein 35 of 888, across 9 files
  • split unrelated changes into separate commitsin 35 of 888, across 30 files

Said here and by no other author read

  • create a recovery point before risky operations
  • test script policy instead of trivial wrapper hooks
  • ask once about creating or switching topic branches
  • ask explicit permission before any github cli command
  • draft pull request text and get human approval
  • stop on unexpected repository state

Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once. Length counted with cl100k_base; the agent that loads this file may tokenize it differently.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.