py2403homework.commands

py2403homework.commands#

面向行,解析和运行命令。

Orienting towards line, parse and run commands.

提示

这个模块只提供解析和执行命令的接口。要在命令行中调用,请使用 python -m py2403homework 以运行 __main__.py

This module only provides interfaces for parsing and executing commands. To invoke in command line, use python -m py2403homework to run __main__.py.

使用样例#

Sample

python -m py2403homework -u Event

选项#

Options

-u <util>, --use <util>, --util=<util>#

选择一个事件类型。<util> 必须存在于 py2403homework.utils 中,否则将引发 ValueError

Select an event type, which must exist in py2403homework.utils, or a ValueError will be raised.

Module Attributes

parser

用于解析命令行参数。run() 的默认值。

Functions

run([args])

运行指定的命令。

py2403homework.commands.parser: ArgumentParser = ArgumentParser(prog='python -m sphinx', usage=None, description='A tool to generate reST content for homework', formatter_class=<class 'argparse.HelpFormatter'>, conflict_handler='error', add_help=True)#

用于解析命令行参数。run() 的默认值。

Used to parse command line parameters. The default value of run().

py2403homework.commands.run(args=None, parser: ArgumentParser = ArgumentParser(prog='python -m sphinx', usage=None, description='A tool to generate reST content for homework', formatter_class=<class 'argparse.HelpFormatter'>, conflict_handler='error', add_help=True))[源代码]#

运行指定的命令。

Run specified command.

参数: