initial template for app based on wuttaweb
with e.g. `poser install` command
This commit is contained in:
commit
46b33a622f
18 changed files with 344 additions and 0 deletions
|
@ -0,0 +1,16 @@
|
|||
# -*- coding: utf-8; -*-
|
||||
"""
|
||||
Pyramid event subscribers
|
||||
"""
|
||||
|
||||
import {{cookiecutter.package_name}}
|
||||
|
||||
|
||||
def add_{{cookiecutter.package_name}}_to_context(event):
|
||||
renderer_globals = event
|
||||
renderer_globals['{{cookiecutter.package_name}}'] = {{cookiecutter.package_name}}
|
||||
|
||||
|
||||
def includeme(config):
|
||||
config.include('wuttaweb.subscribers')
|
||||
config.add_subscriber(add_{{cookiecutter.package_name}}_to_context, 'pyramid.events.BeforeRender')
|
Loading…
Add table
Add a link
Reference in a new issue