summaryrefslogtreecommitdiff
path: root/home/xyz/.local/bin
diff options
context:
space:
mode:
Diffstat (limited to 'home/xyz/.local/bin')
-rwxr-xr-xhome/xyz/.local/bin/upd11
1 files changed, 10 insertions, 1 deletions
diff --git a/home/xyz/.local/bin/upd b/home/xyz/.local/bin/upd
index 4ccc9c4b..7878fd95 100755
--- a/home/xyz/.local/bin/upd
+++ b/home/xyz/.local/bin/upd
@@ -9,6 +9,14 @@ all () {
music
usb
xmr
+ backup
+}
+
+backup () {
+ # https://wiki.archlinux.org/title/Duplicity
+ # Need // for absolute path, see manpage URL FORMAT section. If not use //, will store to /home/xyz/home/xyz/...
+ # --files-from has a bug, this bug makes source url that is / not working while /home works, more see vq notes
+ duplicity --ssh-askpass --use-agent --encrypt-sign-key FDA389A17B94BCE0E2FA3D71842BFD347BE06812 --full-if-older-than 1Y --include-filelist "$XDG_CONFIG_HOME/myconf/upd_rsync_files" --exclude / / scp://ka//home/xyz/backup
}
clean () {
@@ -121,9 +129,10 @@ music () {
if [ $# -eq 0 ]; then
fast
else
- while getopts acfjmMpqrux opt; do
+ while getopts abcfjmMpqrux opt; do
case $opt in
a)all;;
+ b)backup;;
c)clean;;
f)fast;;
j)userjs;;