]> gitweb.fluxo.info Git - borger.git/commitdiff
Fix: use --glob-archives instead of the deprecated --prefix option
authorSilvio Rhatto <rhatto@riseup.net>
Fri, 12 Jul 2024 13:59:10 +0000 (10:59 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Fri, 12 Jul 2024 13:59:10 +0000 (10:59 -0300)
borger

diff --git a/borger b/borger
index 7e35c3890bd432b8131996acd5dd3e94d38a3275..899b738fd7674c491270baf507145022b7b91f49 100755 (executable)
--- a/borger
+++ b/borger
@@ -180,13 +180,16 @@ function borger_create {
 # one specific archive and not apply to archives also.
 function borger_prune {
   info "Pruning repository..."
-  borg prune                     \
-    --list                       \
-    --prefix "${PLACEHOLDER}-"   \
-    --show-rc                    \
-    --keep-daily    $KEEPDAILY   \
-    --keep-weekly   $KEEPWEEKLY  \
-    --keep-monthly  $KEEPMONTHLY \
+  borg prune                          \
+    --list                            \
+    # Option "--prefix" has been deprecated.
+    # Use "--glob-archives 'yourprefix*'" (-a) instead.
+    #--prefix "${PLACEHOLDER}-"       \
+    --glob-archives ${PLACEHOLDER}'*' \
+    --show-rc                         \
+    --keep-daily    $KEEPDAILY        \
+    --keep-weekly   $KEEPWEEKLY       \
+    --keep-monthly  $KEEPMONTHLY      \
 
   prune_exit=$?