summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTill Höppner2017-06-05 18:06:02 +0200
committerTill Höppner2017-06-05 18:06:02 +0200
commitd76c4d8985cae86fd1f2b00c4690f1d2720c63a4 (patch)
tree50b48eb6089da13e72e8daecfd70e60d64b87f8f
parent0a24af10e61241c24c22069d33c1893c9a516686 (diff)
downloadzsh-d76c4d8985cae86fd1f2b00c4690f1d2720c63a4.tar.gz
zsh-d76c4d8985cae86fd1f2b00c4690f1d2720c63a4.tar.xz
zsh-d76c4d8985cae86fd1f2b00c4690f1d2720c63a4.zip
Don't require rg for filter alias
-rw-r--r--conf.d/90-alias.zsh8
1 files changed, 7 insertions, 1 deletions
diff --git a/conf.d/90-alias.zsh b/conf.d/90-alias.zsh
index da6219d..610fdce 100644
--- a/conf.d/90-alias.zsh
+++ b/conf.d/90-alias.zsh
@@ -36,7 +36,13 @@ alias ta='task add'
alias pe=patchelf
alias -g L='| less '
-alias -g F='| rg -i '
+
+if (($+commands[rg])); then
+ alias -g F='| rg -i '
+else
+ alias -g F='| grep -i '
+fi
+
alias -g X='| xargs '
alias -g SDN=' >/dev/null '
alias -g EDN=' 2>/dev/null '