Tags
#version-control
src refspec
CI/CD
Git "error: src refspec main does not match any": commit first, or use the right branch name
Fix Git "error: src refspec main does not match any" on push: you have no commits yet, or your branch is called master. Check with git branch, then commit or rename it.
Beginner · 4 min read
refusing to merge unrelated histories
CI/CD
Git "fatal: refusing to merge unrelated histories": when the flag is safe, and when it isn't
Fix Git "fatal: refusing to merge unrelated histories": why it happens, how to use --allow-unrelated-histories safely, and how to spot a wrong remote or shallow clone.
Beginner · 4 min read