Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
tips:pyramid [2015/08/05 16:59] – [bower] scipio | tips:pyramid [2015/08/18 12:32] (current) – [yml] scipio | ||
---|---|---|---|
Line 45: | Line 45: | ||
sudo apt-get install npm | sudo apt-get install npm | ||
sudo npm install -g bower | sudo npm install -g bower | ||
- | </ | ||
- | |||
- | < | ||
- | < | ||
- | pip install pyramid_bowerstatic | ||
</ | </ | ||
Install module (library) | Install module (library) | ||
< | < | ||
+ | # cd < | ||
bower install angular-bootstrap | bower install angular-bootstrap | ||
</ | </ | ||
+ | Libraries: | ||
+ | * angular | ||
+ | * angular-bootstrap | ||
+ | * angular-wamp | ||
+ | * autobahn | ||
+ | * bootstrap | ||
+ | * jquery | ||
+ | * leafelet-bouncemarker | ||
+ | * leaflet | ||
+ | * Leaflet.label | ||
+ | In __init__.py | ||
+ | < | ||
+ | config.add_static_view(' | ||
+ | </ | ||
+ | |||
+ | In template | ||
+ | <code html> | ||
+ | <link href=" | ||
+ | <script src=" | ||
+ | <script src=" | ||
+ | <script src=" | ||
+ | </ | ||
===== aio ===== | ===== aio ===== | ||
Line 89: | Line 107: | ||
< | < | ||
gunicorn --paste development.ini | gunicorn --paste development.ini | ||
+ | </ | ||
+ | |||
+ | ===== yaml ===== | ||
+ | |||
+ | Use yaml file as configuration container. See [[http:// | ||
+ | |||
+ | setup.py | ||
+ | < | ||
+ | requires = [ | ||
+ | ... | ||
+ | ' | ||
+ | .... | ||
+ | </ | ||
+ | |||
+ | __init__.py | ||
+ | < | ||
+ | config.include(' | ||
+ | </ | ||
+ | |||
+ | |||
+ | *ini | ||
+ | < | ||
+ | yaml.location = / | ||
+ | env = dev | ||
+ | </ | ||
+ | |||
+ | config.yml | ||
+ | < | ||
+ | configurator: | ||
+ | serial_code : ' | ||
+ | serial.port : '/ | ||
+ | serial.speed : 9600 | ||
+ | test.serial.port : '/ | ||
+ | test.serial.speed : 9600 | ||
+ | wamp.router.url : ' | ||
+ | wamp.router.push : ' | ||
+ | wamp.realm : ' | ||
</ | </ | ||