Awesome-omni-skill git-workflow

Designs git workflows covering branching strategies, trunk-based development, stacked changes, conventional commits, CI/CD pipelines, and repository hygiene. Use when setting up branching models, writing commit messages, configuring GitHub Actions, managing stacked PRs, cleaning stale branches, creating issue templates, or recovering lost commits.

install
source · Clone the upstream repo
git clone https://github.com/diegosouzapw/awesome-omni-skill
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/diegosouzapw/awesome-omni-skill "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/devops/git-workflow" ~/.claude/skills/diegosouzapw-awesome-omni-skill-git-workflow-59b9b9 && rm -rf "$T"
manifest: skills/devops/git-workflow/SKILL.md
source content

Git Workflow

Covers branching strategies, conventional commits, CI/CD automation, repository hygiene, and git internals. GitHub CLI usage is handled by a separate

github-cli
skill; this skill focuses on git workflow patterns and CI/CD configuration.

Quick Reference

AreaKey Practice
BranchingTrunk-based development with short-lived feature branches
CommitsConventional commits with imperative mood
HistoryLinear history via rebase; squash noisy commits
PRsSmall, stacked changes; no mega PRs
Main branchAlways deployable; broken main is an emergency
CI/CDModular GitHub Actions with reusable workflows
MergingGreen CI + review required before merge
VersioningSemantic Release or Changesets (never manual)
BranchesMax 48 hours lifespan; auto-prune stale/merged
SecretsOIDC Connect in pipelines; never hardcode tokens
SigningSign commits with SSH or GPG keys for verified authorship

Branch Naming

TypeUse ForExample
featNew features
feat/add-user-auth
fixBug fixes
fix/login-redirect
choreMaintenance
chore/update-deps
docsDocumentation
docs/api-reference
refactorCode restructuring
refactor/auth-module

Conventional Commit Types

TypePurposeVersion Bump
feat
New featuresMinor
fix
Bug fixesPatch
docs
Documentation onlyNone
style
Formatting, no logic changesNone
refactor
Neither fix nor featureNone
perf
Performance improvementsPatch
test
Adding or correcting testsNone
build
Build system or external dependenciesNone
ci
CI configuration changesNone
chore
Tooling, maintenance, non-src changesNone
revert
Revert a previous commitVaries

Append

!
after type/scope for breaking changes (major version bump).

Pre-Merge Checks

All PRs require before merge:

  • Lint
  • Type check
  • Tests
  • Security scan
  • Review approval (human or automated)

Auto-merge is acceptable for low-risk PRs when pipeline succeeds.

Troubleshooting

IssueResolution
Merge conflicts on long-running branchRebase onto main frequently; break remaining work into new branch if over 48 hours
Broken main branchTreat as emergency; revert offending commit, then fix forward on a branch
Lost commits or data recoveryUse git reflog and object inspection (
git cat-file
,
git fsck
)
CI pipeline failuresCheck reusable workflow versions; verify OIDC permissions
Stacked PR conflicts after rebaseRestack entire chain from base; Graphite handles automatically with
gt restack
Large file accidentally committedUse
git filter-repo
to remove from history (not
git filter-branch
)

Common Mistakes

MistakeCorrect Pattern
Keeping feature branches alive longer than 48 hoursMerge or rebase daily; break large work into stacked PRs
Committing directly to main without branch protectionEnable branch protection rules requiring CI and review
Using merge commits that clutter historyRebase and squash to maintain linear history
Hardcoding tokens in GitHub Actions workflowsUse OIDC Connect for authentication in CI/CD pipelines
Creating monolithic CI workflows in a single fileSplit into reusable workflows and composite actions
Fix bug
as commit message
fix(scope): correct bug description
(conventional)
feat: Added feature
(past tense)
feat: add feature
(imperative mood, lowercase)
Using
git filter-branch
for history rewriting
Use
git filter-repo
(faster, safer, officially recommended)
Pushing to main directlyCreate feature branch first
Unsigned commits in shared repositoriesConfigure commit signing with SSH or GPG keys

Delegation

  • Audit repository branch hygiene and stale branches: Use
    Explore
    agent to list and classify branch age and merge status
  • Set up CI/CD pipelines with reusable workflows: Use
    Task
    agent to create modular GitHub Actions configurations
  • Design branching strategy for a new project: Use
    Plan
    agent to evaluate trunk-based vs Git Flow based on team needs

References