From d1facecc69e3a2638b508b4120094873cdb7bcf2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexis=20M=C3=A9taireau?= Date: Tue, 21 Mar 2017 15:08:42 +0100 Subject: Create a Makefile to ease development --- budget/run.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'budget/run.py') diff --git a/budget/run.py b/budget/run.py index f006ae9..9745b60 100644 --- a/budget/run.py +++ b/budget/run.py @@ -1,4 +1,5 @@ import os +import os.path import warnings from flask import Flask, g, request, session @@ -11,6 +12,7 @@ from api import api from utils import PrefixedWSGI from utils import minimal_round +__HERE__ = os.path.dirname(os.path.abspath(__file__)) app = Flask(__name__) @@ -65,7 +67,7 @@ if pre_alembic_db(): # auto-execute migrations on runtime with app.app_context(): - upgrade() + upgrade(os.path.join(__HERE__, 'migrations')) # mail mail.init_app(app) -- cgit v1.1