diff options
Diffstat (limited to '.config/zsh/utils.zsh')
-rw-r--r-- | .config/zsh/utils.zsh | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/.config/zsh/utils.zsh b/.config/zsh/utils.zsh index 486484a..bc986d9 100644 --- a/.config/zsh/utils.zsh +++ b/.config/zsh/utils.zsh @@ -6,9 +6,7 @@ function has () { } # cat -if has bat; then - alias cat='bat --plain --paging=never' -fi +has bat && alias cat='bat --plain --paging=never' # should consider another alias for --show-all (and --number on base cat) but it's not a good default # diff @@ -35,9 +33,7 @@ else fi # tree -if has tree; then - alias tree='tree -C' -fi +has tree && alias tree='tree -C' # mkdir alias mkdir='mkdir -p' @@ -49,9 +45,7 @@ alias dd="dd status=progress oflag=direct,sync" alias df="df -TH --exclude-type=tmpfs --exclude-type=devtmpfs --exclude-type=squashfs" # gpg -if has gpg2; then - alias gpg='gpg2' -fi +has gpg2 && alias gpg='gpg2' # cygwin-specific if [[ "$OSTYPE" == 'cygwin' ]]; then |