/ ok then, are we done now?
This commit is contained in:
@@ -79,24 +79,17 @@ deploy_file() {
|
|||||||
echo ""
|
echo ""
|
||||||
echo "${file_name_trg}:"
|
echo "${file_name_trg}:"
|
||||||
|
|
||||||
echo "<!> _src_path: ${_src_path}"
|
|
||||||
echo "<!> _trg_path: ${_trg_path}"
|
|
||||||
echo "<!> file_name_src: ${file_name_src}"
|
|
||||||
echo "<!> file_name_trg: ${file_name_trg}"
|
|
||||||
|
|
||||||
suffix1=".zip"
|
suffix1=".zip"
|
||||||
suffix2=".tar.xz"
|
suffix2=".tar.xz"
|
||||||
if [[ ${file_name_src} == *$suffix1 ]] ; then
|
if [[ ${file_name_src} == *$suffix1 ]] ; then
|
||||||
echo "unzipping ${file_name_src}"
|
echo "unzipping '${_src_path}'"
|
||||||
# -o: overwrite without prompting
|
# -o: overwrite without prompting
|
||||||
echo "<!> _src_path: ${_src_path}"
|
|
||||||
echo "<!> _trg_path: ${_trg_path}"
|
|
||||||
unzip -o ${_src_path} -d ${_trg_path}
|
unzip -o ${_src_path} -d ${_trg_path}
|
||||||
elif [[ ${file_name_src} == *$suffix2 ]] ; then
|
elif [[ ${file_name_src} == *$suffix2 ]] ; then
|
||||||
echo "un-taring ${file_name_src}"
|
echo "un-taring '${_src_path}'"
|
||||||
tar -xf ${_src_path} -C ${_trg_path}
|
tar -xf ${_src_path} -C ${_trg_path}
|
||||||
else
|
else
|
||||||
echo "copying ${_src_path}"
|
echo "copying '${_src_path}'"
|
||||||
# -f (--force): overwrite without confirmation
|
# -f (--force): overwrite without confirmation
|
||||||
cp --force --recursive ${_src_path} ${_trg_path}
|
cp --force --recursive ${_src_path} ${_trg_path}
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user