From b42e43e3b622af1b8c04a8298e26817343f5e4a1 Mon Sep 17 00:00:00 2001 From: Kyle Lawlor Date: Wed, 31 Aug 2016 12:37:36 -0400 Subject: [PATCH] Better workflow for flaskr and other basic apps (#2000) - adds `from flaskr import app` to top-level in flaskr module - effect is that `export FLASK_APP=flaskr` works over the more verbose `export FLASK_APP=flaskr.flask` - see the readme for how to run - all tests are passing with `py.test` or `python setup.py test` (in venv) --- examples/flaskr/README | 2 +- examples/flaskr/flaskr/__init__.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/flaskr/README b/examples/flaskr/README index 3cb021e7..90860ff2 100644 --- a/examples/flaskr/README +++ b/examples/flaskr/README @@ -19,7 +19,7 @@ 3. Instruct flask to use the right application - export FLASK_APP=flaskr.flaskr + export FLASK_APP=flaskr 4. initialize the database with this command: diff --git a/examples/flaskr/flaskr/__init__.py b/examples/flaskr/flaskr/__init__.py index e69de29b..14a36539 100644 --- a/examples/flaskr/flaskr/__init__.py +++ b/examples/flaskr/flaskr/__init__.py @@ -0,0 +1 @@ +from flaskr import app \ No newline at end of file