diff --git a/__init__.py b/home/__init__.py similarity index 100% rename from __init__.py rename to home/__init__.py diff --git a/app.py b/home/entry.py similarity index 85% rename from app.py rename to home/entry.py index 39594f8..06827c8 100644 --- a/app.py +++ b/home/entry.py @@ -1,8 +1,8 @@ from flask import Flask -from start import services +from . import services app = Flask(__name__) -app.config.from_object('start.settings') +app.config.from_object('home.settings') @app.route('/currency') def currency(): @@ -16,7 +16,6 @@ def weather(): def photos(): return services.photos.get(app.config['UNSPLASH_KEY']) - @app.route('/') def hello_world(): return 'Hello, World!' diff --git a/home/services/__init__.py b/home/services/__init__.py new file mode 100644 index 0000000..406e6b8 --- /dev/null +++ b/home/services/__init__.py @@ -0,0 +1 @@ +from . import currency, photos, weather diff --git a/services/currency.py b/home/services/currency.py similarity index 100% rename from services/currency.py rename to home/services/currency.py diff --git a/services/photos.py b/home/services/photos.py similarity index 100% rename from services/photos.py rename to home/services/photos.py diff --git a/services/weather.py b/home/services/weather.py similarity index 100% rename from services/weather.py rename to home/services/weather.py diff --git a/settings.py.example b/home/settings.py.example similarity index 100% rename from settings.py.example rename to home/settings.py.example diff --git a/services/__init__.py b/services/__init__.py deleted file mode 100644 index 50f8c7b..0000000 --- a/services/__init__.py +++ /dev/null @@ -1,4 +0,0 @@ -from . import weather -from . import currency -from . import photos - diff --git a/wsgi.py b/wsgi.py new file mode 100644 index 0000000..be1cc22 --- /dev/null +++ b/wsgi.py @@ -0,0 +1,4 @@ +from home.entry import app + +if __name__ == '__main__': + app.run()