Git cheatsheet

12 September 2007

Reverting staged changes

Just say you've made changes to a file and staged them using git add the_file and you decide you don't want to make those changes after all, you fix this using the checkout command:

git checkout the_file

Resolving merge conflicts

git mergetool

Merging a branch back into the trunk

# checkout trunk
git checkout master
git merge project_branch

See also

Tags

git