Răsfoiți Sursa

Merge pull request #6310 from hexagonrecursion/bp-no-slash

Backport: docs: explain the difference between a path that ends with or without a slash
TW 3 ani în urmă
părinte
comite
007c562384
1 a modificat fișierele cu 5 adăugiri și 0 ștergeri
  1. 5 0
      src/borg/archiver.py

+ 5 - 0
src/borg/archiver.py

@@ -2260,6 +2260,11 @@ class Archiver:
         ``mount``. Starting with Borg 1.2 this behaviour will be changed to
         accept both absolute and relative paths.
 
+        A directory exclusion pattern can end either with or without a slash ('/').
+        If it ends with a slash, such as `some/path/`, the directory will be
+        included but not its content. If it does not end with a slash, such as
+        `some/path`, both the directory and content will be excluded.
+
         File patterns support these styles: fnmatch, shell, regular expressions,
         path prefixes and path full-matches. By default, fnmatch is used for
         ``--exclude`` patterns and shell-style is used for the ``--pattern`` option.