Explorar o código

Fleshing out NEWS for the Borg 2 changes.

Dan Helfman %!s(int64=2) %!d(string=hai) anos
pai
achega
89d201c8ff
Modificáronse 4 ficheiros con 14 adicións e 12 borrados
  1. 9 7
      NEWS
  2. 2 2
      borgmatic/borg/list.py
  3. 1 1
      borgmatic/config/normalize.py
  4. 2 2
      tests/unit/config/test_normalize.py

+ 9 - 7
NEWS

@@ -1,18 +1,20 @@
 1.7.0.dev0
  * #557: Support for Borg 2 while still working with Borg 1. This includes new borgmatic actions
    like "rcreate" (replaces "init"), "rlist" (list archives in repository), and "rinfo" (show
-   repository info). If you install Borg 2, you'll need to manually "borg transfer" or "borgmatic
-   transfer" your existing Borg 1 repositories before use. See the Borg 2.0 changelog for more
-   information about Borg 2: https://www.borgbackup.org/releases/borg-2.0.html
+   repository info). For the most part, borgmatic tries to smooth over differences between Borg 1
+   and 2 to make your upgrade process easier. However, there are still a few cases where Borg made
+   breaking changes, such as moving flags from "borg list" to "borg rlist". See the Borg 2.0
+   changelog for more information (https://www.borgbackup.org/releases/borg-2.0.html). If you
+   install Borg 2, you'll need to manually "borg transfer" or "borgmatic transfer" your existing
+   Borg 1 repositories before use.
  * #557: Rename several configuration options to match Borg 2: "remote_rate_limit" is now
    "upload_rate_limit", "numeric_owner" is "numeric_ids", and "bsd_flags" is "flags". borgmatic
    still works with the old options.
  * #557: Remote repository paths without the "ssh://" syntax are deprecated but still supported for
-   now. However, remote repository paths containing "~" will no longer work.
+   now. Remote repository paths containing "~" are deprecated in borgmatic and no longer work in
+   Borg 2.
  * #557: Omitting the "--archive" flag on the "list" action is deprecated when using Borg 2. Use
-   the new "rlist" action instead. And when using the "--archive" or "--find" flags on the "list"
-   action with Borg 2, several flags are no longer supported: "--prefix", "--glob-archives",
-   "--sort-by", "--first", and "--last".
+   the new "rlist" action instead.
  * #565: Fix handling of "repository" and "data" consistency checks to prevent invalid Borg flags.
  * #566: Modify "mount" and "extract" actions to require the "--repository" flag when multiple
    repositories are configured.

+ 2 - 2
borgmatic/borg/list.py

@@ -95,7 +95,7 @@ def list_archive(
     if not list_arguments.archive and not list_arguments.find_paths:
         if feature.available(feature.Feature.RLIST, local_borg_version):
             logger.warning(
-                'Omitting the --archive flag on the list action is deprecated when using Borg 2.x. Use the rlist action instead.'
+                'Omitting the --archive flag on the list action is deprecated when using Borg 2.x+. Use the rlist action instead.'
             )
 
         rlist_arguments = argparse.Namespace(
@@ -117,7 +117,7 @@ def list_archive(
         for flag_name in ('prefix', 'glob-archives', 'sort-by', 'first', 'last'):
             if getattr(list_arguments, flag_name.replace('-', '_'), None):
                 raise ValueError(
-                    f'The --{flag_name} flag on the list action is not supported when using the --archive/--find flags and Borg 2.x.'
+                    f'The --{flag_name} flag on the list action is not supported when using the --archive/--find flags and Borg 2.x+.'
                 )
 
     if list_arguments.json:

+ 1 - 1
borgmatic/config/normalize.py

@@ -60,7 +60,7 @@ def normalize(config_filename, config):
                         dict(
                             levelno=logging.WARNING,
                             levelname='WARNING',
-                            msg=f'{config_filename}: Repository paths containing "~" are deprecated in borgmatic and no longer work in Borg 2.',
+                            msg=f'{config_filename}: Repository paths containing "~" are deprecated in borgmatic and no longer work in Borg 2.x+.',
                         )
                     )
                 )

+ 2 - 2
tests/unit/config/test_normalize.py

@@ -74,8 +74,8 @@ from borgmatic.config import normalize as module
             True,
         ),
         (
-            {'location': {'repositories': ['ssh://foo@bar/repo']}},
-            {'location': {'repositories': ['ssh://foo@bar/repo']}},
+            {'location': {'repositories': ['ssh://foo@bar:1234/repo']}},
+            {'location': {'repositories': ['ssh://foo@bar:1234/repo']}},
             False,
         ),
     ),