git-flow — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited git-flow (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Version control is a record other people (and future you) read to understand why the code is the way it is. Commits should be small, focused, well-described, and safe to share. History should be bisectable for [[fault-recovery]], reviewable for [[review-gate]], and revertible for [[launch-readiness]] — a wall of WIP in one commit defeats all three.
Follow the project's merge and branch conventions when they exist. This skill is the baseline when none are defined.
Pairs with [[incremental-delivery]] for commit-sized slices, [[pipeline-ops]] for CI before merge, [[review-gate]] before opening a PR, [[launch-readiness]] for release tags and rollback, and [[hardening]] for never committing secrets.
mainSkip heavy ceremony for trivial one-line fixes — still write a real message and run checks if the repo requires them.
main, master, develop — whatever the project uses).main.feature/add-guest-checkout
fix/null-total-on-empty-cart
chore/upgrade-eslint-9
hotfix/payment-422-regressionEach commit should be one logical change that leaves the tree in a working state ([[incremental-delivery]]):
| Good single commit | Bad bundled commit |
|---|---|
Add TaxService + tests | Feature + refactor + lint fix + dependency bump |
Fix null cart in OrderSummary | "WIP" with 40 files |
| Revert broken deploy | Revert + new feature in same commit |
Commit at green — tests and lint pass for what you changed. Don't commit known-broken intermediate state unless the team explicitly uses stacked PRs / draft WIP on a private branch.
Before each commit:
git status
git diff # review what you're about to record
# run relevant tests / lint per project normsSeparate refactor from behavior change when possible — reviewers and git bisect depend on it.
The diff shows what changed. The message owns why.
Format:
Short imperative subject (~50 chars, no period)
Optional body: context, trade-offs, ticket link, what you rejected.
Wrap at ~72 chars.
Fixes #123Subject examples:
Add idempotency key to order creation endpoint
Fix race in session refresh when tab wakes from sleep
Revert "cache user permissions globally"Avoid: fix, wip, stuff, asdf, misc, address comments (say what changed instead).
Body when needed:
Reference tickets (Fixes #, Refs #) so history links to issue context.
Before every commit, scan the diff for:
.env, credentials ([[hardening]]). If leaked: rotate the secret;removing from git isn't enough.
dist/, node_modules/, __pycache__/, build output (use .gitignore).console.log, commented code blocks, temporary flags.Keep .gitignore current when new tooling adds output dirs. Use git check-ignore to verify.
If secrets hit shared history, treat as incident — rotate credentials and consider history rewrite only with team coordination (rare and painful).
Before opening:
main — resolve conflicts locally, re-run CI.([[launch-readiness]], [[migration-path]]).
Update the PR as you push new commits; don't open "empty" and fill in description days later.
Teams differ; don't improvise on a shared repo:
| Strategy | When teams use it | Notes |
|---|---|---|
| Merge commit | Preserve branch history | Clear merge point; busier log |
| Squash merge | One commit per PR on main | Clean main; detail lives in PR |
| Rebase merge | Linear main | Rewrites branch commits onto tip |
Updating your branch with latest `main`:
git rebase origin/main) — linear history; only on your feature branch before merge.git merge origin/main) — preserves branch history; safer if others push to your branch.Never rebase a branch others are actively committing to without agreement.
After merge: delete the feature branch (remote + local) to reduce clutter.
When merge/rebase stops with conflicts:
<<<<<<< markers and integrate intent, not just syntax.git add resolved files; continue merge/rebase.If conflicts are huge, the branch may have drifted too long — consider rebasing earlier next time or splitting the PR.
Never force-push (git push --force) to branches others build on — main, shared feature branches, release branches. It rewrites their base and can destroy unpushed work.
Safe to rewrite — your local-only branch, or your feature branch before anyone else pulled it (and team allows force-with-lease on feature branches).
Prefer:
main — adds a commit that undoes a bad one; safe for shared history.If you must undo a pushed commit on a shared branch, revert — don't reset and force-push.
Uncommitted work in wrong direction
git stash push -m "describe work"
# or commit on a throwaway branch before experimentingWrong files staged
git restore --staged <file>
git restore <file> # discard working copy if neededLast commit wrong but not pushed
git commit --amend # only if HEAD is yours and not pushed sharedLast commit pushed to shared `main`
git revert <bad-commit-sha> # new commit that undoes it — don't force-push mainLost commit after reset
git reflog
git checkout -b recovery <sha-from-reflog>Cherry-pick one fix onto another branch:
git cherry-pick <sha>Panic rule: stop before push --force; check git status, git log, and whether others use the branch.
Releases ([[launch-readiness]]):
main at the release point — v1.4.0, annotated message with changelog highlights.release/1.4) if the project maintains patch lines.Hotfixes:
main tip ifthey've diverged.
main and release branch so the fix isn't lost on next deploy.v1.4.1).Document deploy order if migrations or config must land first ([[migration-path]]).
Start a feature
Fetch → branch from latest main → small commits at green → push early for backup.
PR feedback
One commit per logical feedback round (or squash locally if team squashes on merge). Reply on threads; don't force-push without re-running CI.
Long-running branch
Merge or rebase main weekly minimum; smaller PRs upstream reduce pain.
CI failed after push
Reproduce locally → fix → one commit → push. Don't pile unrelated fixes.
Accidentally committed secret
Rotate secret immediately → remove from tree → never commit the new secret → team process for history if the old one was pushed.
Need to undo merged PR on `main`
git revert the merge commit (may need -m 1 for merge commits) → deploy revert → fix forward in new PR.
Experimental spike
Branch spike/name — may be messy locally; don't merge without cleaning history or squash per convention.
.gitignore will catch it later." — Review the diff; ignored files don't help if already tracked.wip, fix, stuff, or asdfmain, master, or a branch others usemainmainmain if applicable~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.