mercurial/localrepo.py
changeset 49164 a932cad26d37
parent 48946 642e31cb55f0
parent 49148 db3f8e5cc965
child 49192 2ab79873786e
--- a/mercurial/localrepo.py	Mon Apr 25 11:09:33 2022 +0200
+++ b/mercurial/localrepo.py	Wed May 04 18:17:44 2022 +0200
@@ -3175,7 +3175,7 @@
             # Save commit message in case this transaction gets rolled back
             # (e.g. by a pretxncommit hook).  Leave the content alone on
             # the assumption that the user will use the same editor again.
-            msgfn = self.savecommitmessage(cctx._text)
+            msg_path = self.savecommitmessage(cctx._text)
 
             # commit subs and write new state
             if subs:
@@ -3205,13 +3205,14 @@
             except:  # re-raises
                 if edited:
                     self.ui.write(
-                        _(b'note: commit message saved in %s\n') % msgfn
+                        _(b'note: commit message saved in %s\n') % msg_path
                     )
                     self.ui.write(
                         _(
                             b"note: use 'hg commit --logfile "
-                            b".hg/last-message.txt --edit' to reuse it\n"
+                            b"%s --edit' to reuse it\n"
                         )
+                        % msg_path
                     )
                 raise