summaryrefslogtreecommitdiff
path: root/bin/pkg
diff options
context:
space:
mode:
Diffstat (limited to 'bin/pkg')
-rwxr-xr-xbin/pkg4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/pkg b/bin/pkg
index be0f0bd..8a3f609 100755
--- a/bin/pkg
+++ b/bin/pkg
@@ -135,9 +135,9 @@ if [[ ! -d $PDIR ]] {
##
# Protocol
-if [[ ${PKG_ROOT#ssh} != $PKG_ROOT ]] {
+if [[ $PKG_ROOT == ssh://* ]] {
PKG_PROTO='ssh'
-} elif [[ ${PKG_ROOT#'/'} != $PKG_ROOT ]] {
+} elif [[ $PKG_ROOT == /* ]] {
PKG_PROTO='file'
} else {
die "Error: Unknown protocol in PKG_ROOT '$PKG_ROOT'"