Browse Source

term: Adds diff alias

main
creton32 2 weeks ago
parent
commit
b73ed0d1ac
  1. 1
      term/.config/zsh/.aliases
  2. 7
      term/.config/zsh/settings/utils

1
term/.config/zsh/.aliases

@ -85,6 +85,7 @@ alias gr="gia rm"
alias grc="gia rm --cached"
alias gs="gia status"
alias gd="gia diff"
alias gds="gia diff --staged"
alias gl="gia log"
alias gpm="gia push"
alias gb="gia branch"

7
term/.config/zsh/settings/utils

@ -29,7 +29,12 @@ gia() {
;;
log) git log --oneline --decorate ;;
"status") git status --short ;;
"diff") git diff "$1" "$2" ;;
"diff")
case "$2" in
--staged) git diff --staged "$3" ;;
*) git diff "$3";;
esac
;;
"log") git log ;;
"reflog") git reflog ;;
"merge") git merge --no-commit "$2" "$curbranch" ;;

Loading…
Cancel
Save