From f03bf1f54715c578dd238cbe2b00b91d95ce4469 Mon Sep 17 00:00:00 2001 From: Otho Date: Wed, 23 Nov 2022 22:56:12 -0500 Subject: [PATCH] Added test more for create_datasets. --- backup.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/backup.sh b/backup.sh index c3201e7..e764cee 100755 --- a/backup.sh +++ b/backup.sh @@ -44,8 +44,13 @@ read_datasets() { create_datasets() { # should compare_datasets and only create missing or possibly error. + for dataset in `cat ${datasets_file}`; do - zfs create -p ${BG_ROOT}/$dataset + if [ $BG_TEST_MODE = "TRUE" ]; then + echo zfs create -p ${BG_ROOT}/$dataset + else + zfs create -p ${BG_ROOT}/$dataset + fi done }