Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Aliases in the .gitconfig file
- [alias]
- a = add
- ac = !git add . && git commit -m
- al = "!git config -l | grep alias | cut -c 7-"
- amend = !git add -A && git commit --amend --no-edit
- br = branch
- c = commit
- cl = clone
- co = checkout
- cp = cherry-pick
- f = fetch
- info = remote show origin
- l = log --oneline --graph --all
- last = log -1 HEAD
- ll = log --pretty=format:"%C(yellow)%h\\ %ad%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --date=short --graph --all
- lr = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative --all
- m = merge
- n = !git checkout -b
- p = !git push origin $(git rev-parse --abbrev-ref HEAD)
- pl = pull
- r = reset
- s = status
- unstage = reset --soft HEAD^
- unstageh = reset --hard HEAD^
- #Aliases in the bash-shell
- #edit .bashrc file
- alias g='git'
- alias go='git checkout'
- To apply changes to bash-shell need to log out and log back in, or use command source ~/.bashrc
Add Comment
Please, Sign In to add comment