[PATCH 2 of 5] i18n, hgk: mark command line options for translation

Martin Geisler mg at daimi.au.dk
Sat Sep 6 09:36:46 CDT 2008


# HG changeset patch
# User Martin Geisler <mg at daimi.au.dk>
# Date 1220709519 -7200
# Node ID cb8b7cf462ca86f9e559aa784ac987ac1096f147
# Parent  d69d85cd80eefc9a42dc0a51eedf6785b7174bee
i18n, hgk: mark command line options for translation

diff --git a/hgext/hgk.py b/hgext/hgk.py
--- a/hgext/hgk.py
+++ b/hgext/hgk.py
@@ -323,34 +323,34 @@
 cmdtable = {
     "^view":
         (view,
-         [('l', 'limit', '', 'limit number of changes displayed')],
-         'hg view [-l LIMIT] [REVRANGE]'),
+         [('l', 'limit', '', _('limit number of changes displayed'))],
+         _('hg view [-l LIMIT] [REVRANGE]')),
     "debug-diff-tree":
         (difftree,
-         [('p', 'patch', None, 'generate patch'),
-          ('r', 'recursive', None, 'recursive'),
-          ('P', 'pretty', None, 'pretty'),
-          ('s', 'stdin', None, 'stdin'),
-          ('C', 'copy', None, 'detect copies'),
-          ('S', 'search', "", 'search')],
-         'hg git-diff-tree [OPTION]... NODE1 NODE2 [FILE]...'),
+         [('p', 'patch', None, _('generate patch')),
+          ('r', 'recursive', None, _('recursive')),
+          ('P', 'pretty', None, _('pretty')),
+          ('s', 'stdin', None, _('stdin')),
+          ('C', 'copy', None, _('detect copies')),
+          ('S', 'search', "", _('search'))],
+         _('hg git-diff-tree [OPTION]... NODE1 NODE2 [FILE]...')),
     "debug-cat-file":
         (catfile,
-         [('s', 'stdin', None, 'stdin')],
-         'hg debug-cat-file [OPTION]... TYPE FILE'),
+         [('s', 'stdin', None, _('stdin'))],
+         _('hg debug-cat-file [OPTION]... TYPE FILE')),
     "debug-config":
-        (config, [], 'hg debug-config'),
+        (config, [], _('hg debug-config')),
     "debug-merge-base":
-        (base, [], 'hg debug-merge-base node node'),
+        (base, [], _('hg debug-merge-base node node')),
     "debug-rev-parse":
         (revparse,
-         [('', 'default', '', 'ignored')],
-         'hg debug-rev-parse REV'),
+         [('', 'default', '', _('ignored'))],
+         _('hg debug-rev-parse REV')),
     "debug-rev-list":
         (revlist,
-         [('H', 'header', None, 'header'),
-          ('t', 'topo-order', None, 'topo-order'),
-          ('p', 'parents', None, 'parents'),
-          ('n', 'max-count', 0, 'max-count')],
-         'hg debug-rev-list [options] revs'),
+         [('H', 'header', None, _('header')),
+          ('t', 'topo-order', None, _('topo-order')),
+          ('p', 'parents', None, _('parents')),
+          ('n', 'max-count', 0, _('max-count'))],
+         _('hg debug-rev-list [options] revs')),
 }


More information about the Mercurial-devel mailing list