Record source changes, compare revisions and collaborate through branches.
Before starting: Files, folders, and a text editor.
Practice project: Version a small project and practice branch changes in a disposable copy.
Module 1: Version Control Foundations & Git Architecture
- Git Overview, Version Control Systems (CVCS vs DVCS) & Architecture
- Git Installation, Shell Environment & Initial Configuration (`git config`)
- Git Plumbing vs Porcelain & The Three Trees Architecture
- Initializing a Repository (`git init`) & Project Scaffolding
- Cloning Remote Repositories (`git clone` & Shallow Clones)
Module 2: Basic Snapshotting & Everyday Workflow
- Inspecting Project Status & Changes (`git status`)
- The Staging Area / Index (`git add` & Interactive Patch `git add -p`)
- Committing Snapshots & Crafting Semantic Commit Messages (`git commit`)
- Viewing Working Tree & Staged Differences (`git diff`)
- Removing & Renaming Tracked Files (`git rm` & `git mv`)
Module 3: Ignoring Files & Commit History Inspection
- Ignoring Unwanted Files with `.gitignore` & Global Ignore Rules
- Exploring History with `git log` (Formatting, Graphs, Oneline, Authors)
- Filtering Logs by Date, Author, File Path & Regex Commit Search
- Inspecting Individual Commits & Metadata (`git show`)
- File Archaeology & Line-by-Line Authorship (`git blame`)
Module 4: Branching & Context Switching
- Git Branching Model & Pointer Mechanics (`git branch`)
- Switching Branches & Detached HEAD State (`git switch` & `git checkout`)
- Modern File Restoration (`git restore` vs `git checkout`)
- Temporary Context Switching with `git stash` (Push, Pop, List, Apply, Drop)
- Git Worktrees for Parallel Branch Development (`git worktree`)
Module 5: Merging, Rebasing & Conflict Resolution
- Basic Branch Merging & Fast-Forward vs Three-Way Merge (`git merge`)
- Anatomy of Merge Conflicts & Resolution Workflows
- Three-Way Merge Tools & Re-recording Merge Resolutions (`git rerere`)
- Linear History with Git Rebase (`git rebase` vs `git merge`)
- Interactive Rebasing for Clean Commits (`git rebase -i` Squash, Reword, Drop)
Module 6: Undoing Changes & History Rewriting
- Amending the Last Commit (`git commit --amend`)
- Reverting Historical Commits Safely (`git revert`)
- Resetting State: Soft, Mixed & Hard (`git reset`)
- The Ultimate Safety Net: Git Reflog (`git reflog` & Dangling Commit Recovery)
- Selective Commit Transplantation with `git cherry-pick`
Module 7: Remotes, Collaboration & GitHub Workflows
- Managing Remote Repositories (`git remote` Add, Rename, Remove, Prune)
- Fetching Remote Data without Merging (`git fetch`)
- Integrating Remote Changes (`git pull` vs `git pull --rebase`)
- Publishing Local Work to Remotes (`git push` & Upstream Tracking `-u`)
- GitHub Pull Request Workflow, Code Reviews & Protected Branches
Module 8: Tagging, Releases & Advanced Navigation
- Lightweight vs Annotated Tags (`git tag` & GPG Signatures)
- Binary Search for Bugs with `git bisect` (Automated & Manual)
- Fast Substring & Regex Search across Repository (`git grep`)
- Monorepos & Large Repos: Sparse Checkout & Partial Clones
- Handling Big Assets with Git LFS (Large File Storage)
Module 9: Submodules, Subtrees & Automation Hooks
- Managing External Repositories with `git submodule`
- Seamless Dependency Inlining with `git subtree`
- Client-Side Git Hooks (pre-commit, commit-msg, pre-push)
- Modern Linting with Husky & Lint-Staged
- Server-Side Git Hooks & Automated CI/CD Integration
Module 10: Git Internals, Plumbing & Production Operations
- The `.git` Directory Layout & Storage Architecture
- Git Object Model: Blobs, Trees, Commits & Annotated Tags (`git cat-file`)
- Garbage Collection, Packfiles & Pruning (`git gc` & `git prune`)
- GPG / SSH Commit Signing & Identity Verification
- Git Disaster Recovery, Corruption Repair & Production Best Practices
Inspect Git changes before attempting recovery
Choose a recovery operation only after identifying where the useful version lives. git status describes the working tree and staging area. git diff shows unstaged tracked changes; git diff --staged shows the next snapshot. The reflog records local reference movements but is not a permanent backup. Make a copy of valuable files before destructive commands.
Git installed; use a disposable practice repository
git status --short
git diff
git diff --staged
git log --oneline -5
git reflog -5Check the output
Output depends on your repository. These commands inspect state and do not discard your edits.Create a temporary branch before experimenting. Describe why resetting a branch and reverting a commit have different effects on shared history.
Open the Git learning path on DevStudyHub · Play coding games on this blog
No comments:
Post a Comment
Please do not enter any spam link in the comment box.