Skip to content

Instantly share code, notes, and snippets.

@fdocr
Created September 8, 2016 21:43
Show Gist options
  • Save fdocr/184be32c076fd99d8d15a89093265ecf to your computer and use it in GitHub Desktop.
Save fdocr/184be32c076fd99d8d15a89093265ecf to your computer and use it in GitHub Desktop.
Useful git commands to remember
#Remove staged file
git reset HEAD -- path/to/file
#Remove all staged files
git reset HEAD -- .
#Delete local branch
git branch -d branch_name
#Delete remote branch
git push origin --delete <branchName>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment