summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDaniel Friesel <derf@derf.homelinux.org>2009-04-04 19:28:33 +0200
committerDaniel Friesel <derf@derf.homelinux.org>2009-04-04 19:28:33 +0200
commit5170f250a7be45076b420debb8d8f5cf1b8aad4c (patch)
tree39720b8fda8092f2c2dc666bd9ab9890c29f37b4 /include
parentd4993229956a3510acd19045931fea05107a1209 (diff)
pkglist: Check if we got the right arguments, just in case
Diffstat (limited to 'include')
-rwxr-xr-xinclude/pkglist6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/pkglist b/include/pkglist
index 305d248..eb705c8 100755
--- a/include/pkglist
+++ b/include/pkglist
@@ -1,6 +1,12 @@
#!/usr/bin/env zsh
## on the PKG_HOST: list available packages
## used by pkg remote-update
+# the PKG_PATH (package root path) is given as first argument ($1)
+
+if [[ ! -d $1 ]] {
+ echo "$0: package root directory '$1' does not exist!" >&2
+ exit 1
+}
# change into package root directory (first argument)
cd $1