Fixing Git problems · 3 min
Cancel an active merge, preserve valuable resolution edits, and verify whether pre-existing local changes were restored as expected.
Read guide ↗: Abort an unfinished Git merge carefullyFixing Git problems · 3 min
Cancel an active rebase, preserve useful conflict-resolution work, and distinguish abort from quit or undoing a completed rewrite.
Read guide ↗: Abort a Git rebase and verify the original branchFixing Git problems · 3 min
Resolve a blocked commit by checking the effective Git name and email, choosing the right scope, and preserving the staged snapshot.
Read guide ↗: Fix Git’s “Author identity unknown” errorFixing Git problems · 3 min
Rename a tracked path’s capitalization on case-insensitive filesystems, inspect the staged result, and check references on case-sensitive systems.
Read guide ↗: Record a case-only filename rename in GitFixing Git problems · 3 min
Save misplaced commits under a new branch, determine whether they were shared, and separate preservation from removing them elsewhere.
Read guide ↗: Preserve a commit made on the wrong Git branchFixing Git problems · 3 min
Choose the correct tracking branch or explicit push destination when Git cannot infer an upstream for your current branch.
Read guide ↗: Fix “current branch has no upstream” deliberatelyFixing Git problems · 3 min
Attach detached-HEAD work to a named branch before switching away, inspect the saved commits, and recover carefully if you already left.
Read guide ↗: Save commits made in detached HEAD stateFixing Git problems · 3 min
Check repository ownership and trust before adding a narrowly scoped safe.directory exception, and avoid disabling the protection globally.
Read guide ↗: Investigate Git’s dubious-ownership warning safelyFixing Git problems · 3 min
Compare line-ending and whitespace views, inspect attributes, and separate mechanical conversion from actual content changes.
Read guide ↗: Diagnose a Git diff that marks every line changedFixing Git problems · 3 min
Trace a missing untracked file to its ignore source, distinguish local and global rules, and correct the narrowest applicable pattern.
Read guide ↗: Find which Git ignore rule hides a new fileFixing Git problems · 3 min
Separate expired credentials, wrong accounts, token permissions, and repository policy when HTTPS Git authentication fails.
Read guide ↗: Diagnose GitHub HTTPS authentication failuresFixing Git problems · 3 min
Check the SSH host, username, offered key, and account association without disabling host verification or exposing private keys.
Read guide ↗: Fix GitHub SSH “Permission denied (publickey)” carefullyFixing Git problems · 3 min
Check clone URL, authenticated account, repository access, and organization requirements before changing Git remotes or credentials.
Read guide ↗: Diagnose GitHub “Repository not found” in the terminalFixing Git problems · 3 min
Determine whether a Git lock is active or stale before removing anything, and verify the repository after an interrupted operation.
Read guide ↗: Handle an existing Git index.lock without risking concurrent workFixing Git problems · 3 min
Find the oversized object in pending history, choose appropriate storage, and avoid assuming a later deletion removes an earlier large commit.
Read guide ↗: Handle a GitHub push rejected for a large fileFixing Git problems · 3 min
Recognize Git LFS pointer text, check installation and access, and retrieve the actual object without replacing the pointer by hand.
Read guide ↗: Why a Git LFS file contains a pointer instead of dataFixing Git problems · 3 min
Identify overlapping tracked edits before a branch switch or merge, preserve them, and retry without using force or broad resets.
Read guide ↗: Preserve work when Git says local changes would be overwrittenFixing Git problems · 3 min
Check shallow history, fetch refspecs, and remote availability before concluding an older commit or branch was deleted.
Read guide ↗: Find why Git cannot see an old commit or remote branchFixing Git problems · 3 min
Diagnose Git’s repository-location error without deleting metadata or initializing a new repository over an existing project.
Read guide ↗: Fix “not a git repository” by finding the right folderFixing Git problems · 3 min
Check saved files, repository location, staging, and ignore rules when Git’s clean-state message disagrees with your editor.
Read guide ↗: Why Git says “nothing to commit” after you edited filesFixing Git problems · 3 min
Distinguish missing files, wrong branch names, quoting problems, and unfetched references when Git says a pathspec did not match.
Read guide ↗: Fix a Git pathspec error by checking names and contextFixing Git problems · 3 min
Inspect local and remote commits before choosing merge, rebase, or fast-forward-only behavior for a divergent Git pull.
Read guide ↗: Resolve Git’s divergent-branches pull warningFixing Git problems · 3 min
Inspect remote changes behind a rejected Git push, preserve local work, and integrate deliberately without routine force pushes.
Read guide ↗: Handle a non-fast-forward Git push rejection safelyFixing Git problems · 3 min
Find the former branch tip through local reflogs or other references, verify its commits, and recreate a branch without moving existing ones.
Read guide ↗: Recover a deleted local Git branch from its commitFixing Git problems · 3 min
Use reflog entries to locate a previous branch position, inspect candidates, and create a recovery reference before further changes.
Read guide ↗: Find a lost Git commit with the local reflogFixing Git problems · 3 min
Inspect an existing origin remote and decide whether to reuse it, change its URL, or add a separately named destination.
Read guide ↗: Fix “remote origin already exists” without removing historyFixing Git problems · 3 min
Determine whether a deletion is unstaged, staged, or committed, then restore only the intended path from a verified source.
Read guide ↗: Restore an accidentally deleted tracked file in GitFixing Git problems · 3 min
Understand why reversing an old commit can conflict with newer work, then preserve intended behavior while completing or canceling the revert.
Read guide ↗: Resolve or abort a conflicting Git revertFixing Git problems · 3 min
Check local branch names and commit existence before repairing a Git push refspec error or renaming any branch.
Read guide ↗: Fix “src refspec does not match any” without guessingFixing Git problems · 3 min
Inspect recorded submodule URLs and revisions, initialize only trusted dependencies, and avoid accidentally upgrading them to unrelated tips.
Read guide ↗: Fill an empty submodule directory after cloningFixing Git problems · 3 min
Keep edits made on the wrong branch, choose a safe destination, and verify where the eventual commit will land without discarding files.
Read guide ↗: Move uncommitted work to the right Git branchFixing Git problems · 3 min
Use a soft reset only after verifying the last commit is local, preserve a recovery branch, and understand the resulting staged changes.
Read guide ↗: Undo an unpublished Git commit while keeping its editsFixing Git problems · 3 min
Identify the active Git operation, resolve conflicting content deliberately, and stage only verified resolutions before continuing.
Read guide ↗: Resolve “unmerged files” before continuing GitFixing Git problems · 3 min
Protect new local files when Git refuses to overwrite them with tracked files from another branch, without broad clean commands.
Read guide ↗: Handle untracked files that block checkout or mergeFixing Git problems · 3 min
Check whether an ignored file is already tracked, then remove only its index entry when that is the intended shared repository change.
Read guide ↗: Why a file in .gitignore still appears in Git changes