+ rclone, gitRepos.sh

ulozto, uloz.to
This commit is contained in:
committer@tuxwarrior
2026-04-04 17:21:57 -05:00
parent bc3f8f7394
commit df0c6345c0
3 changed files with 45 additions and 5 deletions

View File

@@ -18,15 +18,17 @@ if ! [[ -d "$trg_dir" ]]; then
mkdir -p ${trg_dir}
fi
# copy from source to target if source does not exist
# copy from source to target
files=$(shopt -s nullglob dotglob; echo ${trg_dir}/*.conf)
if (( ${#files} ))
then
echo "*.conf file(s) already exist in ${trg_dir}"
echo "overwrite already existing *.conf file(s) in ${trg_dir}?"
read -n 1 -s -r -p "press any key to continue"
echo ""
else
echo "deploy .conf file(s)"
cp ${src_file} ${trg_ssh_dir}
echo "deploying new *.conf file(s) to ${trg_dir}"
fi
cp ${src_file} ${trg_dir}
ls -al ${trg_dir}