aboutsummaryrefslogtreecommitdiff
path: root/ihatemoney/manage.py
AgeCommit message (Collapse)AuthorFilesLines
2018-01-14Use Jinja2 strict rendering.Alexis Métaireau1-8/+6
For this I had to create an Jinja2 explicit environment, so I put a function in `ihatemoney.utils.create_jinja2_env(strict_rendering=False)`. When using this environment and if `strict_rendering` is activated, templates using undefined variables will now error out rather than failing silently.
2018-01-14Fix the supervisord template.Alexis Métaireau1-1/+3
The script was relying on the presence of an environment variable, which is only set when the virtualenv is activated. But a virtualenv does not have to be activated to work (it's possible to call the python command directly). This fixes it by relying on `sys.executable` which should be correct at all times. Fixes #306
2018-01-07manage commands testing (#313)JocelynDelalande1-4/+4
* Rename manage.ConfigTemplate → manage.GenerateConfig To be consistent with the CLI name: `generate-config`. * Add tests for manage.py commands * Run tests from pip-installed package To be able to detect packaging-related issues on test runs. refs #305
2017-12-27Silent stderr output during app init for some commands (#293)JocelynDelalande1-0/+12
Avoid confusing the user for the commands outputing text to the user. fix #277
2017-10-23Enhance install process by generating config files from templates (#275)JocelynDelalande1-1/+39
* Add a command to generate configuration examples Config files are generated from templates (which remplace previous example files). - solve the issue of hard-to-explain configuration examples - ease pkg path seeking (avoid it, actually) - add working defaults for sqlite and unix socket paths (instead of /replace/me/path/example) - move settings comments from default_settings.py to ihatemoney.cfg.j2, as it is the one that will be facing user. * Use generate-config command in install doc Also follow the new working defaults of templates for socket and db path. * Fix doc settings table On the long term, plaintext tables might destroy humanity. * Mention templates dir URL in documentation As requested by @almet
2017-07-07Absolute imports & some other improvements (#243)Alexis Metaireau1-0/+32
* Use absolute imports and rename package to ihatemoney * Add a ihatemoney command * Factorize application creation logic * Refactor the tests * Update the wsgi.py module with the new create_app() function * Fix some styling thanks to Flake8. * Automate Flake8 check in the CI.