From b58381faf09302c6257788cc3f6d5ae21eadc52a Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Tue, 26 Nov 2019 17:04:55 -0500 Subject: [PATCH] Refactor zsh aliases --- config/zsh/aliases.zsh | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/config/zsh/aliases.zsh b/config/zsh/aliases.zsh index 23c116ec..b8508a57 100644 --- a/config/zsh/aliases.zsh +++ b/config/zsh/aliases.zsh @@ -5,14 +5,13 @@ alias mv='mv -i' alias mkdir='mkdir -p' alias wget='wget -c' +alias rg='noglob rg' +alias bc='bc -lq' alias grep='grep --color=auto' alias fgrep='fgrep --color=auto' alias egrep='egrep --color=auto' -alias rg='noglob rg' -alias ag='noglob ag -p $HOME/.config/ag/agignore' - ### convenience alias ..='cd ..' @@ -24,12 +23,17 @@ alias q=exit alias clr=clear alias sudo='sudo ' -alias exa='exa --group-directories-first' -alias l='exa -1' -alias ll='exa -l' -alias la='LC_COLLATE=C exa -la' -alias mk=make +if command -v exa >/dev/null; then + alias exa='exa --group-directories-first' + alias l='exa -1' + alias ll='exa -l' + alias la='LC_COLLATE=C exa -la' +else + alias l='ls -1' + alias ll='ls -l' +fi +alias mk=make alias rcp='rsync -vaP --delete' alias rmirror='rsync -rtvu --delete' alias gurl='curl --compressed'