From 4bd7330229f5f915eac7137c8390bca9ba6116c6 Mon Sep 17 00:00:00 2001 From: Tim Van Baak Date: Wed, 8 Jan 2020 21:44:08 -0800 Subject: [PATCH] Rename app package to server --- amanuensis/cli.py | 4 ++-- amanuensis/{app => server}/__init__.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) rename amanuensis/{app => server}/__init__.py (88%) diff --git a/amanuensis/cli.py b/amanuensis/cli.py index 757673e..6fb571f 100644 --- a/amanuensis/cli.py +++ b/amanuensis/cli.py @@ -108,13 +108,13 @@ def command_generate_secret(args): @add_argument("-p", "--port", default="5000") def command_run(args): """Runs the default Flask development server""" - import app + import server import config if config.get("secret_key") is None: config.logger.error("Can't run server without a secret_key. Run generate-secret first") return -1 - app.app.run(host=args.address, port=args.port) + server.app.run(host=args.address, port=args.port) @add_argument("--username", help="User's login handle") @add_argument("--displayname", help="User's publicly displayed name") diff --git a/amanuensis/app/__init__.py b/amanuensis/server/__init__.py similarity index 88% rename from amanuensis/app/__init__.py rename to amanuensis/server/__init__.py index 44d7a5f..093024c 100644 --- a/amanuensis/app/__init__.py +++ b/amanuensis/server/__init__.py @@ -5,6 +5,6 @@ import config app = Flask(__name__, template_folder="../templates") app.secret_key = bytes.fromhex(config.get('secret_key')) -from .auth import bp +from server.auth import bp app.register_blueprint(auth.bp)