aboutsummaryrefslogtreecommitdiff
path: root/env/.local/bin/scripts/backup/bbackup
blob: 9d0b64aaea5cf9d1a8e6b9ef0a25dc1dd5adfbc4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/sh
cd ~/ || exit

fsynca () {
    # t?
    rsync -RUuavn --delete-after $exclude $syncfile "$target"
}

fsyncb () {
    printf "===confirm changes?\n"
    printf "y/n: "
    read -r uinput
    if [ "$uinput" != "n" ] && [ "$uinput" != "N" ]; then
        printf "\n\n\n"
        rsync -RUuav --progress --delete-after $exclude $syncfile "$target"
        printf "\n===end sync\n---------\n\n"
    fi
}

syncfile="stuff .surf/styles .config/eDEX-UI/ .gnupg .ssh .local/bin/lfimg-sixel .config/FreeTube .config/wlxoverlay .config/newsboat .config/zsh .config/vesktop/themes .config/Pinta .config/cava .config/gajim/theme .local/share/applications/custom .local/share/osu"

target="/mnts/mnt-backups/LINUX FILES/home/iceyrazor"
exclude="--exclude node_modules --exclude node_modules_23 --exclude **/target --exclude LinVAM/pyenv --exclude stuff/custom-linux/LFN --exclude stuff/custom-linux/LFN-borked-lol --exclude stuff/.private-parent/.private/minecraft --exclude /home/iceyrazor/stuff/projects/blender-projects/anim-pose/image-sequence"

fsynca

fsyncb