Slide 14
Slide 14 text
HOOKS FILES (2)
from bento.commands import hooks
@hooks.command
def hello(context):
print "hello nice world"
@hooks.command
def goodbye(context):
print "goodbye cruel world !"
@hooks.startup
def startup(context):
context.set_before("goodbye", "hello")
Dependencies defined outside classes for lower
coupling between commands
Tuesday, 3 July 12