GitXplorerGitXplorer
m

hello-python-plugin

public
3 stars
2 forks
0 issues

Commits

List of commits on branch master.
Unverified
e9c99761929a23087900ad9765d5ca4242a7bbe0

Added utils.py

mmozillazg committed 11 years ago
Unverified
e89605c70bf575c3b4945949251be23cd9fa25f3

init.

mmozillazg committed 11 years ago

README

The README file for this repository.

#尝试实现简单的插件功能

$ python main.py -h
usage: main.py [-h] [--enable PLUGINS]

optional arguments:
-h, --help        show this help message and exit
--enable PLUGINS  enable some plugins (default: [])

默认输出:

$ python main.py
Default: test plugin.

启用插件 foo:

$ python main.py --enable foo
Default: test plugin.
Plugin foo: test plugin.

启用插件 foo, bar:

$ python main.py --enable foo --enable bar
Default: test plugin.
Plugin bar: test plugin.
Plugin foo: test plugin.