Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit98c4001

Browse files
[po] auto sync
1 parenteff3b53 commit98c4001

File tree

1 file changed

+21
-7
lines changed

1 file changed

+21
-7
lines changed

‎library/optparse.po

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1815,6 +1815,8 @@ msgid ""
18151815
"``\"float\"`` and ``\"complex\"`` option arguments are converted directly "
18161816
"with :func:`float` and :func:`complex`, with similar error-handling."
18171817
msgstr""
1818+
"``\"float\"`` 和 ``\"complex\"`` 选项参数会直接通过 :func:`float` 和 :func:`complex` "
1819+
"来转换,使用类似的错误处理。"
18181820

18191821
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1311
18201822
msgid""
@@ -1824,6 +1826,9 @@ msgid ""
18241826
"user-supplied option arguments against this master list and raises "
18251827
":exc:`OptionValueError` if an invalid string is given."
18261828
msgstr""
1829+
"``\"choice\"`` 选项是 ``\"string\"`` 选项的子类型。 :attr:`~Option.choices` "
1830+
"选项属性(由字符串组成的序列)定义了允许的选项参数的集合。 :func:`optparse.check_choice` "
1831+
"将用户提供的选项参数与这个主列表进行比较并会在给出无效的字符串时引发 :exc:`OptionValueError`。"
18271832

18281833
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1321
18291834
msgid"Parsing arguments"
@@ -1833,7 +1838,7 @@ msgstr "解析参数"
18331838
msgid""
18341839
"The whole point of creating and populating an OptionParser is to call its "
18351840
":meth:`parse_args` method::"
1836-
msgstr""
1841+
msgstr"创建和填充 OptionParser 的基本目的是调用其 :meth:`parse_args` 方法::"
18371842

18381843
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1328
18391844
msgid"where the input parameters are"
@@ -1847,7 +1852,7 @@ msgstr "``args``"
18471852

18481853
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1331
18491854
msgid"the list of arguments to process (default: ``sys.argv[1:]``)"
1850-
msgstr""
1855+
msgstr"要处理的参数列表 (默认: ``sys.argv[1:]``)"
18511856

18521857
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1336
18531858
msgid"``values``"
@@ -1859,10 +1864,12 @@ msgid ""
18591864
"new instance of :class:`Values`) -- if you give an existing object, the "
18601865
"option defaults will not be initialized on it"
18611866
msgstr""
1867+
"要用于存储选项参数的 :class:`optparse.Values` 对象 (默认:一个新的 :class:`Values` 实例) -- "
1868+
"如果你给出一个现有对象,则不会基于它来初始化选项的默认值"
18621869

18631870
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1338
18641871
msgid"and the return values are"
1865-
msgstr""
1872+
msgstr"返回值为"
18661873

18671874
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1342
18681875
msgid"``options``"
@@ -1872,12 +1879,12 @@ msgstr "``options``"
18721879
msgid""
18731880
"the same object that was passed in as ``values``, or the optparse.Values "
18741881
"instance created by :mod:`optparse`"
1875-
msgstr""
1882+
msgstr"同一个对象将作为 ``values``,或 :mod:`optparse` 所创建的 optparse.Values 实例传入"
18761883

18771884
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1345
18781885
msgid""
18791886
"the leftover positional arguments after all options have been processed"
1880-
msgstr""
1887+
msgstr"在所有选项被处理完毕后余下的位置参数"
18811888

18821889
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1347
18831890
msgid""
@@ -1886,6 +1893,8 @@ msgid ""
18861893
" one for every option argument stored to an option destination) and returned"
18871894
" by :meth:`parse_args`."
18881895
msgstr""
1896+
"最常见的用法是不提供任何关键字参数。 如果你提供了 ``values``,它将通过重复的 :func:`setattr` "
1897+
"调用来修改(大致为每个存储到指定选项目标的选项参数调用一次)并由 :meth:`parse_args` 返回。"
18891898

18901899
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1352
18911900
msgid""
@@ -1894,28 +1903,33 @@ msgid ""
18941903
"message. This ultimately terminates your process with an exit status of 2 "
18951904
"(the traditional Unix exit status for command-line errors)."
18961905
msgstr""
1906+
"如果 :meth:`parse_args` 在参数列表中遇到任何错误,它将调用 OptionParser 的 :meth:`error` "
1907+
"方法并附带适当的最终用户错误消息。 这会完全终结你的进程并将退出状态设为 2 (传统的针对命令行错误的 Unix 退出状态)。"
18971908

18981909
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1361
18991910
msgid"Querying and manipulating your option parser"
1900-
msgstr""
1911+
msgstr"查询和操纵你的选项解析器"
19011912

19021913
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1363
19031914
msgid""
19041915
"The default behavior of the option parser can be customized slightly, and "
19051916
"you can also poke around your option parser and see what's there. "
19061917
"OptionParser provides several methods to help you out:"
19071918
msgstr""
1919+
"选项解析器的默认行为可被轻度地定制,并且你还可以调整你的选项解析器查看实际效果如何。 OptionParser 提供了一些方法来帮助你进行定制:"
19081920

19091921
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1369
19101922
msgid""
19111923
"Set parsing to stop on the first non-option. For example, if ``-a`` and "
19121924
"``-b`` are both simple options that take no arguments, :mod:`optparse` "
19131925
"normally accepts this syntax::"
19141926
msgstr""
1927+
"设置解析在第一个非选项处停止。 举例来说,如果 ``-a`` 和 ``-b`` 都是不接受参数的简单选项,则 :mod:`optparse` "
1928+
"通常会接受这样的语法::"
19151929

19161930
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1375
19171931
msgid"and treats it as equivalent to ::"
1918-
msgstr""
1932+
msgstr"并会这样处理它 ::"
19191933

19201934
#:/home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:1379
19211935
msgid""

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp