Commit 64ff66fb authored by Daniel STAN's avatar Daniel STAN

draft backup-recv

parent f539b3a3
#!/bin/bash
# Path to the backup fs
FS_DIR=/mnt/backup
# Path to the backup directory (form FS_DIR)
BACK_DIR=ailesv
# Extra filter for volumes (sed syntax)
PATTERN=1d_.*
if [ "$1" = "available" ]; then
# TODO escape
btrfs sub list $FS_DIR | sed "s/^.* path $BACK_DIR\/\($PATTERN\)$/\1/; t; d"
elif [ "$1" = "receive" ]; then
btrfs receive
exit
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment