From 5d5f8d9f5180f733ced33a9cea3ed4dd28a748c5 Mon Sep 17 00:00:00 2001 From: "committer@tuxwarrior" Date: Tue, 27 Aug 2024 16:27:45 -0500 Subject: [PATCH] u --- scripts/99_deploy.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/scripts/99_deploy.sh b/scripts/99_deploy.sh index 43102aa..f535dce 100755 --- a/scripts/99_deploy.sh +++ b/scripts/99_deploy.sh @@ -71,7 +71,7 @@ deploy_file() { _no_chown=$3 _recursive=$4 - if [[ "$_src_path" == *.zip ]] ; then + if [[ "$_src_path" == *.zip ]] || [[ "$_src_path" == *.tar.xz ]] ; then file_name_src=$(basename ${_src_path}) fi @@ -87,13 +87,16 @@ deploy_file() { suffix1=".zip" suffix2=".tar.xz" if [[ ${file_name_src} == *$suffix1 ]] ; then + echo "unzipping ${file_name_src}" # -o: overwrite without prompting - echo "_src_path: ${_src_path}" - echo "_trg_path: ${_trg_path}" + echo " _src_path: ${_src_path}" + echo " _trg_path: ${_trg_path}" unzip -o ${_src_path} -d ${_trg_path} elif [[ ${file_name_src} == *$suffix2 ]] ; then + echo "un-taring ${file_name_src}" tar -xf ${_src_path} -C ${_trg_path} else + echo "copying ${_src_path}" # -f (--force): overwrite without confirmation cp --force --recursive ${_src_path} ${_trg_path} fi