Git, Configuration, Cheatsheet
Use the command below to create aliases, replacing
<alias> with the name of the alias and
<command> with the command to be aliased:
git config --global alias.<alias> <command>
Additionally, you can use edit the configuration file and add many aliases all at once.
[alias] co = checkout cob = checkout -b coo = !git fetch && git checkout br = branch brd = branch -d st = status aa = add -A . unstage = reset --soft HEAD^ cm = commit -m amend = commit --amend -m fix = commit --fixup undo = reset HEAD~1 rv = revert cp = cherry-pick pu = !git push origin `git branch --show-current` fush = push -f mg = merge --no-ff rb = rebase rbc = rebase --continue rba = rebase --abort rbs = rebase --skip rom = !git fetch && git rebase -i origin/master --autosquash save = stash push pop = stash pop apply = stash apply rl = reflog
A collection of cheatsheets to bookmark and come back to whenever you need to look up anything.
Merging a branch is a pretty common Git operation. Learn how fast-forward mode works and its benefits, so you can decide if it's a good fit for you and your team.
Ever needed to create a git commit with a different date? Here's a quick and easy way to do it.
Learn how to add multiple authors to a git commit with this quick and easy tip.