zsh:ls-show-hidden: Fix ./ listing on non-existing
Fix a bug that ls-show-hidden always listed `./` when all other non-flag arguments were non-existing (in addition to their 'No such file...' message).
This commit is contained in:
@@ -49,6 +49,8 @@ done
|
|||||||
# Print working directory when only flags were given as arguments.
|
# Print working directory when only flags were given as arguments.
|
||||||
if ! (( $#dirs + $#files + $non_existing )); then
|
if ! (( $#dirs + $#files + $non_existing )); then
|
||||||
dirs+=.
|
dirs+=.
|
||||||
|
elif ! (( $#dirs + $#files )); then
|
||||||
|
return 2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Just pass everything to ls when the -d flag is given since then the -A flag
|
# Just pass everything to ls when the -d flag is given since then the -A flag
|
||||||
|
|||||||
Reference in New Issue
Block a user