Git Memo
Git command cheat sheet/reference.
Customize Command Parameters
Type values below to dynamically customize variables inside the Git commands.
Configure global Git username
Configure global Git email address
Initialize a new local Git repository
Clone a remote repository
Show state of working directory and staging area
Stage file changes for next commit
Stage all current changes in the directory
Commit staged changes with a message
Amend the last commit with a new message
List local branches
Create a new local branch
Switch to a different branch
Create and switch to a new branch
Delete a local branch
Merge a branch into the active branch
Save modified and staged changes temporarily
Restore the most recently stashed changes
List all currently stashed changes
Discard the most recently stashed changes
Show commit history simplified to one line per commit
Rebase active branch onto specified branch
Interactive rebase of last n commits
List remote connections and their URLs
Push commits to origin remote repository branch
Fetch and merge remote changes into current branch
Undo last commit, keeping changes staged
Undo last commit and discard all changes
Discard changes in a file in working directory