Most developers use Git every day. But 90% only know 3 commands. Here's the complete cheat sheet they're missing. 😳 📌 Basics (jo sab ko pata hona chahiye) main → Default primary branch origin → Default upstream branch HEAD → Current branch pointer HEAD^ → Parent of HEAD HEAD~3 → Great grandparent of HEAD 🌿 Branches git branch --all → List all local and remote branches git checkout hotfix → Switch to existing branch git merge hotfix → Merge branch changes to main git log --graph --oneline → Visual branch history 🚀 Start to Work git init → Create a new local Git repo git clone → Copy a repo git pull → Fetch and update from remote git add [file] → Stage tracked/untracked files git commit → Save staged changes git push origin HEAD → Push local changes to origin ⚔️ Conflicts git diff → See specific local changes git diff --ours → Compare working tree with our branch git diff --theirs → Compare working tree with their branch 🛠️ Useful Tools git archive → Create a release tarball git cherry-pick [commit-id] → Pick any specific commit to your branch The 3 commands most developers don't use but should: → git log --graph --oneline → git cherry-pick → git diff --theirs Save this. Share with a junior dev who needs it. Follow Developers Street for more practical dev tips. 🌐 www.developersstreet.com 📞 +91 9412892908 . . . . #Git #GitHub #VersionControl #SoftwareEngineering #WebDevelopment #DevelopersStreet #CodingTips #TechCareers #FullStackDevelopment #DevOps

To view or add a comment, sign in

Explore content categories