manage.sh: Allow bidirational copying

This commit is contained in:
mollusk 2021-01-31 11:09:01 -07:00
parent 354ff4aa70
commit 323d7d801a

View File

@ -24,14 +24,31 @@ mv_d2(){
exit 1
fi
echo "Moving files from ${remoteDir} to $(pwd)/Diablo II"
cp "${remoteDir}"/* "$(pwd)"/"Diablo II"
case "${1}" in
--from-remote)
echo "Moving files from ${remoteDir} to $(pwd)/Diablo II"
cp "${remoteDir}"/* "$(pwd)"/"Diablo II"
;;
--to-remote)
echo "Moving files to ${remoteDir} from $(pwd)/Diablo II"
cp "$(pwd)"/"Diablo II"/* "${remoteDir}"
;;
*)
echo "--from-remote Move files from real game folder to repo"
echo "--to-remote Move files to real game folder from repo"
;;
esac
}
case "${1}" in
-d2)
mv_d2
mv_d2 "${2}"
;;
*)