mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-26 22:06:35 +01:00
a5507f5b78
Signed-off-by: David Spencer <idlemoor@slackbuilds.org>
15 lines
442 B
Text
15 lines
442 B
Text
PluginBase is a module for Python that enables the development of
|
|
flexible plugin systems in Python.
|
|
|
|
Step 1:
|
|
from pluginbase import PluginBase
|
|
plugin_base = PluginBase(package='yourapplication.plugins')
|
|
|
|
Step 2:
|
|
plugin_source = plugin_base.make_plugin_source(
|
|
searchpath=['./path/to/plugins', './path/to/more/plugins'])
|
|
|
|
Step 3:
|
|
with plugin_source:
|
|
from yourapplication.plugins import my_plugin
|
|
my_plugin.do_something_cool()
|