fix version conflict

This commit is contained in:
Thomas von Dein
2020-12-13 14:54:16 +01:00
parent 6bcdb1ac20
commit 906c59aee8

11
jaildk
View File

@@ -186,12 +186,12 @@ jaildk_build() {
shift shift
base='' base=''
version='' VERSION=''
while getopts "b:v:" arg; do while getopts "b:v:" arg; do
case $arg in case $arg in
b) base=${OPTARG};; b) base=${OPTARG};;
v) version=${OPTARG};; v) VERSION=${OPTARG};;
*) usage_build;; *) usage_build;;
esac esac
done done
@@ -204,10 +204,15 @@ jaildk_build() {
mode=start mode=start
fi fi
die_if_not_exist $jail $version die_if_not_exist $jail $VERSION
load-jail-config $jail load-jail-config $jail
if test -n "$VERSION"; then
# overridden with -v
version=$VERSION
fi
if test -n "$buildbase"; then if test -n "$buildbase"; then
base="$buildbase" base="$buildbase"
elif test -z "$base"; then elif test -z "$base"; then