mirror of
https://github.com/robbyrussell/oh-my-zsh.git
synced 2026-10-02 16:03:47 +02:00
alias-finder: fix wc numeric conditional (#8251)
Never use `[[` for numeric comparisons, for that, we’ll use `((`.
This commit is contained in:
1 parent
9785d24172
commit
e363109a6d
1 file changed
+1
-1
@@ -14,7 +14,7 @@ alias-finder() {
|
||||
esac
|
||||
done
|
||||
cmd=$(sed 's/[].\|$(){}?+*^[]/\\&/g' <<< $cmd) # adds escaping for grep
|
||||
if [[ $(wc -l <<< $cmd) == 1 ]]; then
|
||||
if (( $(wc -l <<< $cmd) == 1 )); then
|
||||
while [[ $cmd != "" ]]; do
|
||||
if [[ $longer = true ]]; then
|
||||
wordStart="'{0,1}"
|
||||
|
||||
Reference in new issue
Block a user