first commit
This commit is contained in:
7
.gitignore
vendored
Normal file
7
.gitignore
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
.vscode/*
|
||||
.DS_Store
|
||||
thumbs.db
|
||||
*debug*
|
||||
*.psd
|
||||
*.zip
|
||||
*.aseprite
|
||||
BIN
data/volcano - backup.map
Normal file
BIN
data/volcano - backup.map
Normal file
Binary file not shown.
BIN
data/volcano - backup2.map
Normal file
BIN
data/volcano - backup2.map
Normal file
Binary file not shown.
BIN
data/volcano.map
Normal file
BIN
data/volcano.map
Normal file
Binary file not shown.
2704
source/volcano.pas
Normal file
2704
source/volcano.pas
Normal file
File diff suppressed because it is too large
Load Diff
34
sync.sh
Executable file
34
sync.sh
Executable file
@@ -0,0 +1,34 @@
|
||||
#!/bin/bash
|
||||
readonly USAGE="
|
||||
USAGE:
|
||||
$(basename "$0") [UPLOAD or DOWNLOAD]"
|
||||
|
||||
function help_message() {
|
||||
echo "$USAGE"
|
||||
}
|
||||
|
||||
PARAMETERS="UPLOAD DOWNLOAD upload download"
|
||||
|
||||
# check if there are all the parameters
|
||||
if [ "$#" -ne 1 ]; then
|
||||
help_message
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# check if the systems parameter is valid
|
||||
if ! echo "$PARAMETERS" | grep -w "$1" >/dev/null; then
|
||||
help_message
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# UPLOAD
|
||||
if [ "$1" = upload ] || [ "$1" = UPLOAD ]; then
|
||||
printf "\n%s\n" "uploading volcano"
|
||||
rsync -azmPu --delete -e 'ssh -p 4545' . sergio@sustancia.synology.me:/home/sergio/backup/code/volcano/
|
||||
rsync -azmPu -e 'ssh -p 4545' . sergio@sustancia.synology.me:/home/sergio/backup/code/volcano.all/
|
||||
fi
|
||||
|
||||
if [ "$1" = download ] || [ "$1" = DOWNLOAD ]; then
|
||||
printf "%s\n" "downloading volcano"
|
||||
rsync -azmP --delete -e 'ssh -p 4545' sergio@sustancia.synology.me:/home/sergio/backup/code/volcano/* .
|
||||
fi
|
||||
Reference in New Issue
Block a user