Skip to content

Instantly share code, notes, and snippets.

@riomyers
Created May 15, 2018 17:09
Show Gist options
  • Save riomyers/c5f4a8081f5bbf498a1aaabdf6af5ed2 to your computer and use it in GitHub Desktop.
Save riomyers/c5f4a8081f5bbf498a1aaabdf6af5ed2 to your computer and use it in GitHub Desktop.

Git Commit Options

Basic Git Commit - (not recommended) opens text editor to add a message

git commit

Commit With Message

git commit -m 'commit message goes here'

Stage and Commit Changes in One Step

git commit -a -m 'commit message goes here'

Add Additional Changes and Modify Previous Commit Message

git commit --amend

Add Additional Changes and Don't Modify Previous Commit Message

git commit -a --amend --no-edit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment