From 81493afa53a1a1d5ff4b417d05febf9f9e2a172b Mon Sep 17 00:00:00 2001 From: René 'Necoro' Neumann Date: Thu, 23 Jul 2020 00:28:47 +0200 Subject: Restructure --- app/__init__.py | 32 -------------------------------- 1 file changed, 32 deletions(-) delete mode 100644 app/__init__.py (limited to 'app/__init__.py') diff --git a/app/__init__.py b/app/__init__.py deleted file mode 100644 index 7c6408a..0000000 --- a/app/__init__.py +++ /dev/null @@ -1,32 +0,0 @@ -from flask import Flask - -# create app -app = Flask('kosten', instance_relative_config = True) - -# force autoescape in all files -app.jinja_env.autoescape = True - -app.jinja_env.lstrip_blocks = True -app.jinja_env.trim_blocks = True - -# load config -app.config.from_object('settings') -app.config.from_pyfile('settings.py', silent = True) - -from .model import db -from .login import login_manager -from . import views - -# commands -@app.cli.command() -def create(): - db.create_all() - -@app.cli.command() -def drop(): - db.drop_all() - -@app.cli.command() -def compile(): - """Compiles all templates.""" - app.jinja_env.compile_templates('comp', zip = None) -- cgit v1.2.3-70-g09d2