Git aliases
I centralize here all my favorite git command to easy use it and be faster.
git undo
How to undo the last commit
git config --global alias.undo 'reset --soft HEAD^'
Usage:
git undo
git upd
How to update from a remote branch
git config --global alias.upd '!f() { git fetch origin && git rebase origin/$1; }; f'
usage
git upd master
git upd develop
...
git new
How to create a new branch
git config --global alias.new "checkout -b"
usage
git new <my_branch>
git st
How to see the current git status
git config --global alias.st "status"
usage
git st
Oldest comments (0)