Guest User

Untitled

a guest
Apr 21st, 2020
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.70 KB | None | 0 0
  1. abbrev-alias -c y="yay"
  2. abbrev-alias -c g="git"
  3. abbrev-alias -c gp="git pull"
  4. abbrev-alias -c gc="git commit"
  5. abbrev-alias -c gpp="git push"
  6. if command -v pacman >/dev/null 2>&1; then
  7. abbrev-alias -c syu="sudo pacman -Syu"
  8. else
  9. abbrev-alias -c syu="sudo apt update && sudo apt upgrade"
  10. fi
  11.  
  12. alias -r | {
  13. while read -r a; do
  14. # don't convert some aliases to abbrevs
  15. case "$a" in
  16. # ls?=* | ll?=* | ls=* | ll=*) continue ;;
  17. z?=* | z=*) continue ;;
  18. cp=* | df=* | free=* | np=* | grep=*) continue ;;
  19. esac
  20. source <(echo "abbrev-alias $a")
  21. done
  22. }
Advertisement
Add Comment
Please, Sign In to add comment