Permalink
Browse files

Merge pull request #137 from jeromedecoster/no-installed-version

abort gracefully if no installed version
  • Loading branch information...
2 parents 76de515 + 7192c3f commit 3ea021043f96a77c636eba55092e0b6f5c5cd6c3 @tj committed Jul 9, 2013
Showing with 1 addition and 0 deletions.
  1. +1 −0 bin/n
View
1 bin/n
@@ -409,6 +409,7 @@ display_remote_versions() {
# Handle arguments
if test $# -eq 0; then
+ test "$(ls -l $VERSIONS_DIR | grep ^d)" || abort "no installed version"
display_versions
else
while test $# -ne 0; do

0 comments on commit 3ea0210

Please sign in to comment.