Commits

Vladimir Zakharov committed 62eece7

Update for compatibility with Mercurial 2.7+

See: http://selenic.com/repo/hg/rev/c58b6ab4c26f

  • Participants
  • Parent commits f482f58

Comments (0)

Files changed (3)

         if resp_file[0] is not None:
             return resp_file[0]
         while True:
-            resps = _('[Ynsfdaq?]')
-            choices = (
-                _('&Yes, shelve this change'),
-                _('&No, skip this change'),
-                _('&Skip remaining changes to this file'),
-                _('Shelve remaining changes to this &file'),
-                _('&Done, skip remaining changes and files'),
-                _('Shelve &all changes to all remaining files'),
-                _('&Quit, shelving no changes'),
-                _('&?')
-            )
-            r = ui.promptchoice("%s %s " % (query, resps), choices)
+            resps = _('[Ynsfdaq?]'
+                      '$$ &Yes, shelve this change'
+                      '$$ &No, skip this change'
+                      '$$ &Skip remaining changes to this file'
+                      '$$ Shelve remaining changes to this &file'
+                      '$$ &Done, skip remaining changes and files'
+                      '$$ Shelve &all changes to all remaining files'
+                      '$$ &Quit, shelving no changes'
+                      '$$ &?'
+                      )
+            r = ui.promptchoice("%s %s" % (query, resps))
             if r == 7:
                 c = shelve.__doc__.find('y - shelve this change')
                 for l in shelve.__doc__[c:].splitlines():

File test-shelve-color.t

   \x1b[0;36;1mold mode 100644\x1b[0m (esc)
   \x1b[0;36;1mnew mode 100755\x1b[0m (esc)
   1 hunks, 2 lines changed
-  \x1b[0;33mshelve changes to 'a'? [Ynsfdaq?] \x1b[0m \x1b[0;35m@@ -2,7 +2,7 @@\x1b[0m (esc)
+  \x1b[0;33mshelve changes to 'a'? [Ynsfdaq?]\x1b[0m \x1b[0;35m@@ -2,7 +2,7 @@\x1b[0m (esc)
    c
    a
    a
    a
    a
    c
-  \x1b[0;33mshelve this change to 'a'? [Ynsfdaq?] \x1b[0m  (no-eol) (esc)
+  \x1b[0;33mshelve this change to 'a'? [Ynsfdaq?]\x1b[0m  (no-eol) (esc)
   $ echo
   

File test-shelve.t

   > EOF
   diff --git a/file1.txt b/file1.txt
   2 hunks, 2 lines changed
-  shelve changes to 'file1.txt'? [Ynsfdaq?]  @@ -1,5 +1,4 @@
+  shelve changes to 'file1.txt'? [Ynsfdaq?] @@ -1,5 +1,4 @@
   -a
    1
    2
    3
    4
-  shelve this change to 'file1.txt'? [Ynsfdaq?]  @@ -2,5 +1,4 @@
+  shelve this change to 'file1.txt'? [Ynsfdaq?] @@ -2,5 +1,4 @@
    1
    2
    3
    4
   -b
-  shelve this change to 'file1.txt'? [Ynsfdaq?]  diff --git a/file2.txt b/file2.txt
+  shelve this change to 'file1.txt'? [Ynsfdaq?] diff --git a/file2.txt b/file2.txt
   2 hunks, 2 lines changed
-  shelve changes to 'file2.txt'? [Ynsfdaq?]  @@ -1,5 +1,4 @@
+  shelve changes to 'file2.txt'? [Ynsfdaq?] @@ -1,5 +1,4 @@
   -a
    1
    2
    3
    4
-  shelve this change to 'file2.txt'? [Ynsfdaq?]  @@ -2,5 +1,4 @@
+  shelve this change to 'file2.txt'? [Ynsfdaq?] @@ -2,5 +1,4 @@
    1
    2
    3
    4
   -b
-  shelve this change to 'file2.txt'? [Ynsfdaq?]  diff --git a/tip.bundle b/tip.bundle
+  shelve this change to 'file2.txt'? [Ynsfdaq?] diff --git a/tip.bundle b/tip.bundle
   this modifies a binary file (all or nothing)
-  shelve changes to 'tip.bundle'? [Ynsfdaq?]   (no-eol)
+  shelve changes to 'tip.bundle'? [Ynsfdaq?]  (no-eol)
 
   $ echo