Skip to content

Commit

Permalink
zshrc: test if ls is GNU ls instead of islinux()
Browse files Browse the repository at this point in the history
  • Loading branch information
moviuro committed Jan 17, 2016
1 parent c06666b commit 1fa194e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion etc/zsh/zshrc
Expand Up @@ -442,7 +442,7 @@ fi

# Natural sorting order on GNU ls(1)
# OSX and IllumOS have a -v option that is not natural sorting
if islinux && ls -v / >/dev/null 2>&1; then
if ls --version |& grep -q 'GNU' >/dev/null 2>&1 && ls -v / >/dev/null 2>&1; then
ls_options+=( -v )
fi

Expand Down

0 comments on commit 1fa194e

Please sign in to comment.