from __future__ import unicode_literals import os import os.path
from app import create_app, db from app.models import User from flask.ext.script import Manager, Shell from flask.ext.migrate import Migrate, MigrateCommand
if os.path.isfile('app.env'): # print('importing environment from app.env...') withopen('app.env') as f: for line in f: ifnot line.lstrip().startswith('#') and'='in line: items = line.strip().split('=', 1) os.environ[str(items[0].strip())] = str(items[1].strip())