From 69806aff7bc5b34a43501727afbb38913ac47626 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 1 Jun 2012 23:16:58 +0530 Subject: [PATCH] ... --- src/calibre/library/cli.py | 2 +- src/calibre/translations/calibre.pot | 30 ++++++++++++++++++---------- src/calibre/utils/config.py | 10 +++++----- 3 files changed, 25 insertions(+), 17 deletions(-) diff --git a/src/calibre/library/cli.py b/src/calibre/library/cli.py index eb53cadb34..89241dc601 100644 --- a/src/calibre/library/cli.py +++ b/src/calibre/library/cli.py @@ -40,7 +40,7 @@ def write_dirtied(db): def get_parser(usage): parser = OptionParser(usage) - go = parser.add_option_group('GLOBAL OPTIONS') + go = parser.add_option_group(_('GLOBAL OPTIONS')) go.add_option('--library-path', '--with-library', default=None, help=_('Path to the calibre library. Default is to use the path stored in the settings.')) return parser diff --git a/src/calibre/translations/calibre.pot b/src/calibre/translations/calibre.pot index ae7132f881..21c895d0e2 100644 --- a/src/calibre/translations/calibre.pot +++ b/src/calibre/translations/calibre.pot @@ -5,8 +5,8 @@ msgid "" msgstr "" "Project-Id-Version: calibre 0.8.54\n" -"POT-Creation-Date: 2012-06-01 21:10+IST\n" -"PO-Revision-Date: 2012-06-01 21:10+IST\n" +"POT-Creation-Date: 2012-06-01 23:16+IST\n" +"PO-Revision-Date: 2012-06-01 23:16+IST\n" "Last-Translator: Automatically generated\n" "Language-Team: LANGUAGE\n" "MIME-Version: 1.0\n" @@ -3072,7 +3072,7 @@ msgid "Producer" msgstr "" #: /home/kovid/work/calibre/src/calibre/ebooks/metadata/book/base.py:773 -#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:939 +#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:937 #: /home/kovid/work/calibre/src/calibre/gui2/preferences/metadata_sources.py:157 #: /home/kovid/work/calibre/src/calibre/library/field_metadata.py:245 msgid "Comments" @@ -3218,7 +3218,7 @@ msgstr "" #: /home/kovid/work/calibre/src/calibre/ebooks/metadata/opf2.py:1434 #: /home/kovid/work/calibre/src/calibre/ebooks/oeb/base.py:1273 -#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:951 +#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:949 #: /home/kovid/work/calibre/src/calibre/gui2/store/search/models.py:41 msgid "Cover" msgstr "" @@ -8397,7 +8397,7 @@ msgid "Standard metadata" msgstr "" #: /home/kovid/work/calibre/src/calibre/gui2/dialogs/metadata_bulk.py:62 -#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:920 +#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:919 msgid "Custom metadata" msgstr "" @@ -11299,7 +11299,7 @@ msgid "Save changes and edit the metadata of %s" msgstr "" #: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:610 -#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:814 +#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:813 msgid "Change cover" msgstr "" @@ -11308,7 +11308,7 @@ msgid "Co&mments" msgstr "" #: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:708 -#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:855 +#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:854 msgid "&Metadata" msgstr "" @@ -11320,11 +11320,11 @@ msgstr "" msgid "C&ustom metadata" msgstr "" -#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:795 +#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:794 msgid "&Comments" msgstr "" -#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:861 +#: /home/kovid/work/calibre/src/calibre/gui2/metadata/single.py:860 msgid "Basic metadata" msgstr "" @@ -15765,6 +15765,10 @@ msgstr "" msgid "Folders raising exception" msgstr "" +#: /home/kovid/work/calibre/src/calibre/library/cli.py:43 +msgid "GLOBAL OPTIONS" +msgstr "" + #: /home/kovid/work/calibre/src/calibre/library/cli.py:44 msgid "Path to the calibre library. Default is to use the path stored in the settings." msgstr "" @@ -16689,11 +16693,15 @@ msgstr "" msgid "Whenever you pass arguments to %prog that have spaces in them, enclose the arguments in quotation marks." msgstr "" -#: /home/kovid/work/calibre/src/calibre/utils/config.py:92 +#: /home/kovid/work/calibre/src/calibre/utils/config.py:94 +msgid "Options" +msgstr "" + +#: /home/kovid/work/calibre/src/calibre/utils/config.py:95 msgid "show this help message and exit" msgstr "" -#: /home/kovid/work/calibre/src/calibre/utils/config.py:93 +#: /home/kovid/work/calibre/src/calibre/utils/config.py:96 msgid "show program's version number and exit" msgstr "" diff --git a/src/calibre/utils/config.py b/src/calibre/utils/config.py index a4ebcb28a1..65e59afbeb 100644 --- a/src/calibre/utils/config.py +++ b/src/calibre/utils/config.py @@ -89,11 +89,11 @@ class OptionParser(_OptionParser): formatter=CustomHelpFormatter(), conflict_handler=conflict_handler, **kwds) self.gui_mode = gui_mode - for o, msg in {'-h':_('show this help message and exit'), '--version': - _("show program's version number and exit")}.iteritems(): - opt = self.get_option(o) - if opt is not None: - opt.help = msg + if False: + # Translatable string from optparse + _("Options") + _("show this help message and exit") + _("show program's version number and exit") def error(self, msg): if self.gui_mode: