From f421234fe70f868e2a2ff3e4b8c4b2fc27c0d673 Mon Sep 17 00:00:00 2001 From: "Eric S. Raymond" Date: Mon, 22 Dec 2014 11:31:13 -0500 Subject: [PATCH] Attempt to fix revspec-parsing bug introduced by commit -a change. All regression tests pass. --- src | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src b/src index af57514..63dd904 100755 --- a/src +++ b/src @@ -1075,12 +1075,15 @@ def commit_method(*args): croak(" %s creation failed, check directory permissions." % repodir) args = list(args) addonly = False + parse_revspec = True while args: if args[0] == '--': args.pop(0) + parse_revspec = False break elif args[0] == '-a': addonly = True + parse_revspec = False args.pop(0) else: break @@ -1088,7 +1091,7 @@ def commit_method(*args): comment = CommentContext("commit", args) ctx = CommandContext("commit", args, require_empty=True, - parse_revspec=not addonly and comment.parse_revspec) + parse_revspec=parse_revspec and comment.parse_revspec) for arg in ctx.args: if not os.path.exists(arg): croak("I see no '%s' here." % arg) -- 2.43.0