0
0
mirror of https://github.com/tj/n.git synced 2024-11-25 07:39:21 +01:00

Added version dir check, if the mkdir fails abort with an error

This commit is contained in:
Dav Glass 2011-01-28 14:46:14 -06:00 committed by Tj Holowaychuk
parent 81a46aa452
commit e9043b7f88

4
bin/n
View File

@ -11,6 +11,10 @@ VERSIONS_DIR=$N_PREFIX/n/versions
test -d $VERSIONS_DIR || mkdir -p $VERSIONS_DIR
if ! test -d $VERSIONS_DIR; then
abort "Failed to create versions directory ($VERSIONS_DIR), do you have permissions to do this?"
fi
# curl / wget support
GET=