0c7ce363c903e1e3255d4d30255ff4790678ace9

Author
hellzbellz <31550512+Hellzbellz123@users.noreply.github.com>
Committer
GitHub <noreply@github.com>
Date

Message

chore(lib): only create `afind` alias if `ack` is installed (#11017)

Diff

 1diff --git a/lib/misc.zsh b/lib/misc.zsh
 2index a5d3af99869c87b0ba621baa30d12bdd5476732e..1f637083a66f3576c7994f958771474a3fbeb5a9 100644
 3--- a/lib/misc.zsh
 4+++ b/lib/misc.zsh
 5@@ -24,10 +24,10 @@ env_default 'LESS' '-R'
 6 ## super user alias
 7 alias _='sudo '
 8 
 9-## more intelligent acking for ubuntu users
10+## more intelligent acking for ubuntu users and no alias for users without ack
11 if (( $+commands[ack-grep] )); then
12   alias afind='ack-grep -il'
13-else
14+elif (( $+commands[ack] )); then
15   alias afind='ack -il'
16 fi
17