Use a file to ignore subvolumes when bootstrapping

When a file with a special name, .btrfish-ignore, exists in the root
of a subvolume, this subvolume is skipped during the bootstrapping
process.
This commit is contained in:
Les De Ridder 2016-06-05 05:33:37 +00:00
parent b7f577bda3
commit f8ada7688c
1 changed files with 6 additions and 2 deletions

View File

@ -22,8 +22,12 @@ for pair in (get-subvol-mounts)
set safepath $subvoldir/$safename
if not test -d $safepath
sudo btrfs subvolume snapshot -r $mount $safepath
set snapshots $snapshots $safepath
if not test -f $mount/.btrfish-ignore
sudo btrfs subvolume snapshot -r $mount $safepath
set snapshots $snapshots $safepath
else
echo ".btrfish-ignore found in $mount, skipping..."
end
end
end