diff options
author | Markos Chandras <mchandras@suse.de> | 2017-07-05 15:06:49 +0100 |
---|---|---|
committer | Trevor Bramwell <tbramwell@linuxfoundation.org> | 2017-08-11 12:56:12 -0700 |
commit | d3affbf2236e8127ea904e51c3b54a089168499c (patch) | |
tree | e1e5b4250f18e2a0d5305a08ab4629a3f30e2b44 | |
parent | bbf912a18cfeecdd95bb6e56498b6e8099a5d927 (diff) |
prototypes: xci: xci-deploy: Set default value for devel parameters
Commit 68412ffc734e ("prototypes: xci: xci-deploy.sh: Append trailing
slash for rsync vars") modified xci-deploy.sh script to append a
trailing slash to the devel variables but it broke the script when
one of these variables was not set (since we run with 'set -eu') with
the following error:
./xci-deploy.sh: line 45: !local_user_var: unbound variable
Fixes: I0103b754585931fa1dcd3966c52d7e4a8f2f63f6
Change-Id: Ic2465ff07348b61e74e191516425cd10d80c1fce
Signed-off-by: Markos Chandras <mchandras@suse.de>
-rwxr-xr-x | xci/xci-deploy.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/xci/xci-deploy.sh b/xci/xci-deploy.sh index a72c9274..d7112565 100755 --- a/xci/xci-deploy.sh +++ b/xci/xci-deploy.sh @@ -42,7 +42,7 @@ source $XCI_PATH/config/env-vars #------------------------------------------------------------------------------- user_local_dev_vars=(OPNFV_RELENG_DEV_PATH OPNFV_OSA_DEV_PATH OPNFV_BIFROST_DEV_PATH) for local_user_var in ${user_local_dev_vars[@]}; do - [[ -n ${!local_user_var} ]] && export $local_user_var=${!local_user_var%/}/ + [[ -n ${!local_user_var:-} ]] && export $local_user_var=${!local_user_var%/}/ done unset user_local_dev_vars local_user_var |