Enter your email below to get insights on starting, running and growing a creative company

Lesser used git commands

Most of these don't see much action day to day, but they're useful when they're useful.

# See a list of recent commits
git log --stat --pretty=short --graph

# Disregard uncommited changes to a file
git checkout -- /PATH/TO/FILE

# Checkout a specific past commit as a new branch

# Amend a commit message before pushing
git commit --amend

# Add staged filed to the last commit (useful for assets)
git commit --amend -C HEAD

# List remote git branches
git branch -a

# See changes to files you've already committed 
git diff --cached
Posted July 2017
© 2014-2018 James Chambers
Learn from my mistakes

Sign up to my mailing list to get insights about starting, running and growing a creative company.