git-mastery

Solid

Advanced Git: rebase, bisect, reflog, cherry-pick, worktrees, LFS. Triggers: rebase, bisect, cherry-pick, reflog, force push, merge conflict, worktree.

AI & Automation 155 stars 19 forks Updated 2 days ago MIT

Install

View on GitHub

Quality Score: 93/100

Stars 20%
73
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# Git Mastery Skill ## ๐Ÿ›ก๏ธ Safety First Protocol - **Never** force push to `main` / `master` / `develop`. - **Always** use `--force-with-lease` instead of `--force`. - **Always** create a backup branch before complex operations: `git branch backup/feature-xyz-pre-rebase` ## Advanced Workflows ### 1. Automated Bug Hunting (Git Bisect) Find the specific commit that introduced a bug. ```bash # Start git bisect start git bisect bad # Current version is broken git bisect good <commit-sha> # Version that worked # Automate with test script git bisect run pytest tests/test_failing_feature.py ``` ### 2. Interactive Interactive Rebase Clean up commit history before merge. ```bash git rebase -i HEAD~n ``` - **squash**: Combine commits. - **reword**: Fix messages. - **dropped**: Remove junk commits. ### 3. Log Analysis Visualize branch topology. ```bash git log --graph --oneline --decorate --all ``` ### 4. Recovery (Reflog) Recover "lost" commits after a bad reset/rebase. ```bash git reflog git reset --hard HEAD@{n} ``` ### 5. Cherry Picking Pick specific commits from other branches. ```bash git cherry-pick <commit-sha> # If valid conflict git add . git cherry-pick --continue ``` ## Commit Message Standard (Conventional Commits) - `feat:` New feature - `fix:` Bug fix - `docs:` Documentation only - `style:` Formatting (white-space, etc) - `refactor:` Code change that neither fixes a bug nor adds a feature - `perf:` Performance improvement - `test:` Adding missing t...

Details

Author
softspark
Repository
softspark/ai-toolkit
Created
2 months ago
Last Updated
2 days ago
Language
Python
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content โ€” not just same category