-
Open new branch:
git checkout -b [branch_name] origin/master
-
"Undo" changes to file:
git checkout /path/to/file
-
Untrack new file:
git reset HEAD /path/to/file
-
View files in commit:
git rev-parse HEAD | xargs -t -n1 git diff-tree --no-commit-id --name-only -r
-
Add changed files to last commit w/o changing commit message:
git commit -a --amend --no-edit
-
Force update a branch:
git push --force origin
Last active
August 2, 2017 20:34
-
-
Save sploiselle/63a05e33851f3eb634d985fd5e7167b3 to your computer and use it in GitHub Desktop.
Tips for Using Git
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment