Repository: borgbackup/borg

Issue:
build_man issue
```
$ python setup.py build_man
...
building man page borg-patterns(1)
docs/borg-patterns.rst:43: (ERROR/3) Unexpected indentation.
docs/borg-patterns.rst:44: (WARNING/2) Block quote ends without a blank line; unexpected unindent.
building man page borg-placeholders(1)
...
```


Discussion:
Related?
```
$ cd docs ; make clean ; make html
...
usage/help.rst.inc:26: WARNING: Unexpected indentation.
usage/help.rst.inc:27: WARNING: Block quote ends without a blank line; unexpected unindent.
...
```


Resolving patch:
diff --git a/src/borg/archiver.py b/src/borg/archiver.py
--- a/src/borg/archiver.py
+++ b/src/borg/archiver.py
@@ -2237,7 +2237,7 @@ def do_break_lock(self, args, repository):
         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. For commands that support patterns in their ``PATH`` argument
+        option. For commands that support patterns in their ``PATH`` argument
         like (``borg list``), the default pattern is path prefix.
 
         Starting with Borg 1.2, for all but regular expression pattern matching
@@ -2358,64 +2358,64 @@ def do_break_lock(self, args, repository):
             EOF
             $ borg create --exclude-from exclude.txt backup /
 
-            A more general and easier to use way to define filename matching patterns exists
-            with the ``--pattern`` and ``--patterns-from`` options. Using these, you may
-            specify the backup roots (starting points) and patterns for inclusion/exclusion.
-            A root path starts with the prefix `R`, followed by a path (a plain path, not a
-            file pattern). An include rule starts with the prefix +, an exclude rule starts
-            with the prefix -, an exclude-norecurse rule starts with !, all followed by a pattern.
-
-            .. note::
-
-                Via ``--pattern`` or ``--patterns-from`` you can define BOTH inclusion and exclusion
-                of files using pattern prefixes ``+`` and ``-``. With ``--exclude`` and
-                ``--exclude-from`` ONLY excludes are defined.
-
-            Inclusion patterns are useful to include paths that are contained in an excluded
-            path. The first matching pattern is used so if an include pattern matches before
-            an exclude pattern, the file is backed up. If an exclude-norecurse pattern matches
-            a directory, it won't recurse into it and won't discover any potential matches for
-            include rules below that directory.
-
-            .. note::
-
-                It's possible that a sub-directory/file is matched while parent directories are not.
-                In that case, parent directories are not backed up thus their user, group, permission,
-                etc. can not be restored.
-
-            Note that the default pattern style for ``--pattern`` and ``--patterns-from`` is
-            shell style (`sh:`), so those patterns behave similar to rsync include/exclude
-            patterns. The pattern style can be set via the `P` prefix.
-
-            Patterns (``--pattern``) and excludes (``--exclude``) from the command line are
-            considered first (in the order of appearance). Then patterns from ``--patterns-from``
-            are added. Exclusion patterns from ``--exclude-from`` files are appended last.
-
-            Examples::
-
-                # backup pics, but not the ones from 2018, except the good ones:
-                # note: using = is essential to avoid cmdline argument parsing issues.
-                borg create --pattern=+pics/2018/good --pattern=-pics/2018 repo::arch pics
-
-                # use a file with patterns:
-                borg create --patterns-from patterns.lst repo::arch
-
-            The patterns.lst file could look like that::
-
-                # "sh:" pattern style is the default, so the following line is not needed:
-                P sh
-                R /
-                # can be rebuild
-                - /home/*/.cache
-                # they're downloads for a reason
-                - /home/*/Downloads
-                # susan is a nice person
-                # include susans home
-                + /home/susan
-                # don't backup the other home directories
-                - /home/*
-                # don't even look in /proc
-                ! /proc\n\n''')
+        A more general and easier to use way to define filename matching patterns exists
+        with the ``--pattern`` and ``--patterns-from`` options. Using these, you may
+        specify the backup roots (starting points) and patterns for inclusion/exclusion.
+        A root path starts with the prefix `R`, followed by a path (a plain path, not a
+        file pattern). An include rule starts with the prefix +, an exclude rule starts
+        with the prefix -, an exclude-norecurse rule starts with !, all followed by a pattern.
+
+        .. note::
+
+            Via ``--pattern`` or ``--patterns-from`` you can define BOTH inclusion and exclusion
+            of files using pattern prefixes ``+`` and ``-``. With ``--exclude`` and
+            ``--exclude-from`` ONLY excludes are defined.
+
+        Inclusion patterns are useful to include paths that are contained in an excluded
+        path. The first matching pattern is used so if an include pattern matches before
+        an exclude pattern, the file is backed up. If an exclude-norecurse pattern matches
+        a directory, it won't recurse into it and won't discover any potential matches for
+        include rules below that directory.
+
+        .. note::
+
+            It's possible that a sub-directory/file is matched while parent directories are not.
+            In that case, parent directories are not backed up thus their user, group, permission,
+            etc. can not be restored.
+
+        Note that the default pattern style for ``--pattern`` and ``--patterns-from`` is
+        shell style (`sh:`), so those patterns behave similar to rsync include/exclude
+        patterns. The pattern style can be set via the `P` prefix.
+
+        Patterns (``--pattern``) and excludes (``--exclude``) from the command line are
+        considered first (in the order of appearance). Then patterns from ``--patterns-from``
+        are added. Exclusion patterns from ``--exclude-from`` files are appended last.
+
+        Examples::
+
+            # backup pics, but not the ones from 2018, except the good ones:
+            # note: using = is essential to avoid cmdline argument parsing issues.
+            borg create --pattern=+pics/2018/good --pattern=-pics/2018 repo::arch pics
+
+            # use a file with patterns:
+            borg create --patterns-from patterns.lst repo::arch
+
+        The patterns.lst file could look like that::
+
+            # "sh:" pattern style is the default, so the following line is not needed:
+            P sh
+            R /
+            # can be rebuild
+            - /home/*/.cache
+            # they're downloads for a reason
+            - /home/*/Downloads
+            # susan is a nice person
+            # include susans home
+            + /home/susan
+            # don't backup the other home directories
+            - /home/*
+            # don't even look in /proc
+            ! /proc\n\n''')
     helptext['placeholders'] = textwrap.dedent('''
         Repository (or Archive) URLs, ``--prefix``, ``--glob-archives``, ``--comment``
         and ``--remote-path`` values support these placeholders:


Test patch: