summaryrefslogtreecommitdiff
path: root/local/bin/org-sync
blob: cc6668128f01c1d4c8b2b30a20654d41854c8ff0 (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/bin/env sh

IS_CONNECTED=$(iwctl station wlp61s0 show | grep "State")

if $(echo $IS_CONNECTED | grep -q "disconnected")
then
    echo "System is not connected to Wifi. Will not sync";
else
    /usr/bin/rclone bisync storage.mccd.space:personal-db ~/personal-db;
    echo "Sync complete";
fi