@@ -380,27 +380,29 @@ msgstr "首先,你需要导入 OptionParser 类;然后在主程序的开头
380380
381381#: /home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:259
382382msgid "Then you can start defining options. The basic syntax is::"
383- msgstr ""
383+ msgstr "然后你可以开始定义选项。 基本语法如下:: "
384384
385385#: /home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:264
386386msgid ""
387387"Each option has one or more option strings, such as ``-f`` or ``--file``, "
388388"and several option attributes that tell :mod:`optparse` what to expect and "
389389"what to do when it encounters that option on the command line."
390390msgstr ""
391+ "每个选项有一个或多个选项字符串,如 ``-f`` 或 ``--file``,以及一些选项属性用来告诉 :mod:`optparse` "
392+ "当它在命令行中遇到该选项时将得到什么和需要做什么。"
391393
392394#: /home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:268
393395msgid ""
394396"Typically, each option will have one short option string and one long option"
395397" string, e.g.::"
396- msgstr ""
398+ msgstr "通常,每个选项都会有一个短选项字符串和一个长选项字符串,例如 :: "
397399
398400#: /home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:273
399401msgid ""
400402"You're free to define as many short option strings and as many long option "
401403"strings as you like (including zero), as long as there is at least one "
402404"option string overall."
403- msgstr ""
405+ msgstr "你可以随你的喜好自由定义任意数量的短选项字符串和任意数量的长选项字符串(包括零个),只要总计至少有一个选项字符串。 "
404406
405407#: /home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:277
406408msgid ""
@@ -410,6 +412,8 @@ msgid ""
410412"reality, :mod:`optparse` encounters *option strings* and looks up options "
411413"from them."
412414msgstr ""
415+ "传给 :meth:`OptionParser.add_option` 的选项字符串实际上是特定调用所定义的选项的标签。 "
416+ "为了表述简单,我们将经常会说在命令行中 *遇到一个选项*;而实际上,:mod:`optparse` 是遇到了 *选项字符串* 并根据它们来查找选项。"
413417
414418#: /home/runner/work/docspush-transifex/docspush-transifex/cpython/Doc/library/optparse.rst:283
415419msgid ""
0 commit comments