From 3dafc6ab2875c4f340279788d25bc6cc33792664 Mon Sep 17 00:00:00 2001 From: Rob Date: Mon, 13 Apr 2020 15:09:16 +0200 Subject: [PATCH] rsync thinkpad T520 on bfds --- rsync-T520-2-bfds/rsync_exclude_list | 11 +++++++++ .../rsync_include_list | 2 +- rsync-T520-2-bfds/rsync_t520_d3v_on_bfds.sh | 16 +++++++++++++ rsync_exclude_list | 17 ------------- rsync_t520_d3v_on_bfds.sh | 24 ------------------- 5 files changed, 28 insertions(+), 42 deletions(-) create mode 100644 rsync-T520-2-bfds/rsync_exclude_list rename rsync_include_list => rsync-T520-2-bfds/rsync_include_list (87%) create mode 100755 rsync-T520-2-bfds/rsync_t520_d3v_on_bfds.sh delete mode 100644 rsync_exclude_list delete mode 100755 rsync_t520_d3v_on_bfds.sh diff --git a/rsync-T520-2-bfds/rsync_exclude_list b/rsync-T520-2-bfds/rsync_exclude_list new file mode 100644 index 0000000..8d9c97c --- /dev/null +++ b/rsync-T520-2-bfds/rsync_exclude_list @@ -0,0 +1,11 @@ +;Bilder ##lieber nicht ausschließen +Trash +.local +.cache +*.deb +Downloads +Mate8-SD +*\[no_backup\]* +*\[no_backup\]*.* +*.iso +*.ISO diff --git a/rsync_include_list b/rsync-T520-2-bfds/rsync_include_list similarity index 87% rename from rsync_include_list rename to rsync-T520-2-bfds/rsync_include_list index bd9a04f..e92d0d1 100644 --- a/rsync_include_list +++ b/rsync-T520-2-bfds/rsync_include_list @@ -1,3 +1,3 @@ Noch nicht probiert, was hier funktioniert und was nicht -/code + /code /Dokumente diff --git a/rsync-T520-2-bfds/rsync_t520_d3v_on_bfds.sh b/rsync-T520-2-bfds/rsync_t520_d3v_on_bfds.sh new file mode 100755 index 0000000..97fca64 --- /dev/null +++ b/rsync-T520-2-bfds/rsync_t520_d3v_on_bfds.sh @@ -0,0 +1,16 @@ +#!/bin/zsh + +exclude='--exclude-from=rsync_exclude_list' +#includefile='--include-from=rsync_include_list' + +sourceDir="/home/rob" +destinationDir="/mnt/bfds/rob/backup/thinkpad-T520/home/rob" +if [ -d "$sourceDir" ]; then + rsync -az --stats --progress $exclude $includefile $sourceDir/$scope bfds:$destinationDir/$scope +fi + +sourceDir="/var/www" +destinationDir="/mnt/bfds/rob/backup/thinkpad-T520/www" +if [ -d "$sourceDir" ]; then + rsync -az --stats --progress $exclude $includefile $sourceDir/$scope bfds:$destinationDir/$scope +fi diff --git a/rsync_exclude_list b/rsync_exclude_list deleted file mode 100644 index 8f7decf..0000000 --- a/rsync_exclude_list +++ /dev/null @@ -1,17 +0,0 @@ -;Bilder ##lieber nicht ausschließen -#local/share/Trash -Trash -local/share/Trash -.cache -*.deb -Musik -Videos -Downloads -Mate8-SD -*\[no_backup\]* -*\[no_backup\]*.* -*.iso -*.ISO - -network-manager network-manager-gnome wicd wicd-daemon wicd-gtk wpasupplicant - diff --git a/rsync_t520_d3v_on_bfds.sh b/rsync_t520_d3v_on_bfds.sh deleted file mode 100755 index 873c33c..0000000 --- a/rsync_t520_d3v_on_bfds.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/zsh - -sourceDir="/home/rob" -destinationDir="/media/3TB/Backup/tp_t520_d3v" -excludefile='--exclude-from=rsync_exclude_list' -#includefile='--include-from=rsync_include_list' - -if [ -d "$sourceDir" ]; then - - scope="code" - rsync -arlh --stats --progress $excludefile $includefile $sourceDir/$scope bfds:$destinationDir/$scope - #rsync -arlh "$excludes" "$includes" --stats $sourceDir root@kodi:$destinationDir -vvv - - - scope="data" - rsync -arlh --stats --progress $excludefile $includefile $sourceDir/$scope bfds:$destinationDir/$scope - - - #Documents - rsync -arlh --stats --progress $excludefile $includefile $sourceDir/Documents bfds:$destinationDir/Documents - - #dotfiles -fi -