move all existing in subfolders

This commit is contained in:
trnq1ll0 committed 2025-03-11 23:16:02 +01:00
1 parent cc069f63ef
commit 6491336e60
48 files changed

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
#!/bin/sh
# Hint: to exclude any directory (for example an cache dir)
# place the CACHEDIR.TAG file in there: https://bford.info/cachedir/
# don't forget the signature in there and set the parameter: --exclude-caches
export RESTIC_REPOSITORY=bfds:/mnt/bfds/rob-restic-backups/restic-repo-t520-user
export RESTIC_PASSWORD=kopenhagenhatsuperinternetwirklich
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
# backup the whole user dir to bfds
#restic -r sftp:${RESTIC_REPOSITORY} backup /home/rob --exclude-caches --exclude-file=${SCRIPT_DIR}/backup.excludes
# find files in backup. $1 is the parameter from comand line.
# example: $ backup-list-files.sh /home/rob/Pictures > output.txt
# find all files containing Pictures path and out into output.txt
restic -r sftp:${RESTIC_REPOSITORY} find $1
#restic -r sftp:bfds:/mnt/bfds/rob-restic-backups/restic-repo-t520-user backup /home/rob --exclude-caches
+16
View File
@@ -0,0 +1,16 @@
#!/bin/sh
# Hint: to exclude any directory (for example an cache dir)
# place the CACHEDIR.TAG file in there: https://bford.info/cachedir/
# don't forget the signature in there and set the parameter: --exclude-caches
export RESTIC_REPOSITORY=bfds:/mnt/bfds/rob-restic-backups/restic-repo-t520-user
export RESTIC_PASSWORD=kopenhagenhatsuperinternetwirklich
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
# backup the whole user dir to bfds
# restic -r sftp:${RESTIC_REPOSITORY} backup /home/rob --exclude-caches --exclude-file=${SCRIPT_DIR}/backup.excludes
#restic stats -r sftp:${RESTIC_REPOSITORY}
restic snapshots -r sftp:${RESTIC_REPOSITORY}
+21
View File
@@ -0,0 +1,21 @@
#Just Caches
**/.cache/
**/cache/
**/Cache/
#Logs
**/log/
**/logs/
**/Log/
**/Logs/
*.log
# VSCode
/home/rob/.config/Code/Cache
/home/rob/.config/Code/CachedData
/home/rob/.config/Code/CachedExtensions
/home/rob/.config/Code/CachedExtensionVSIXs
# Firefox und Co.
/home/rob/.mozilla
/home/rob/Downloads
+16
View File
@@ -0,0 +1,16 @@
#!/bin/sh
# Hint: to exclude any directory (for example an cache dir)
# place the CACHEDIR.TAG file in there: https://bford.info/cachedir/
# don't forget the signature in there and set the parameter: --exclude-caches
export RESTIC_REPOSITORY=bfds:/mnt/bfds/rob-restic-backups/restic-repo-t520-user
export RESTIC_PASSWORD=kopenhagenhatsuperinternetwirklich
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
# backup the whole user dir to bfds
restic -r sftp:${RESTIC_REPOSITORY} backup /home/rob --exclude-caches --exclude-file=${SCRIPT_DIR}/backup.excludes
#restic -r sftp:bfds:/mnt/bfds/rob-restic-backups/restic-repo-t520-user backup /home/rob --exclude-caches
+12
View File
@@ -0,0 +1,12 @@
#!/bin/sh
# mount the backup into the file system
MOUNTPOINT="/mnt/restic-backup-me"
echo Erstelle Ordner $MOUNTPOINT via sudo
sudo mkdir $MOUNTPOINT
sudo chown rob:rob $MOUNTPOINT
echo Mount Backup
./restic-bfds.sh mount $MOUNTPOINT
+13
View File
@@ -0,0 +1,13 @@
#!/bin/sh
# Hint: to exclude any directory (for example an cache dir)
# place the CACHEDIR.TAG file in there: https://bford.info/cachedir/
# don't forget the signature in there and set the parameter: --exclude-caches
export RESTIC_REPOSITORY=bfds:/mnt/bfds/rob-restic-backups/restic-repo-t520-user
export RESTIC_PASSWORD=kopenhagenhatsuperinternetwirklich
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
# restic wrapper for use with command line arguments
restic -r sftp:${RESTIC_REPOSITORY} $1 $2 $3 $4 $5 $6 $7 $8 $9
+5
View File
@@ -0,0 +1,5 @@
#!/bin/sh
INCLUDE_FILES="/home/rob/Pictures/2022/*"
RESTORE_PATH="/home/rob/Pictures/from_restic/"
./restic-bfds.sh restore --target "$RESTORE_PATH" --include "$INCLUDE_FILES" latest