local-bin/apsalar/nc-sync

20 lines
432 B
Plaintext
Raw Permalink Normal View History

2024-04-04 06:35:00 +03:00
#!/bin/sh
if [ -f /tmp/nc-sync.lock ]; then
notify-send "Lock found, exiting"
exit 1
else
touch /tmp/nc-sync.lock
# Needed for cronjob
source /home/siina/.config/private.env
NC_DIR="/home/siina/Nextcloud"
NC_URL="https://cloud.criminallycute.fi"
notify-send "Nextcloud Sync Syncing ..."
nextcloudcmd -u $NC_USER -p $NC_PASS $NC_DIR $NC_URL
notify-send "Nextcloud Sync Done syncing"
rm /tmp/nc-sync.lock
fi
2024-04-04 06:35:00 +03:00