From 0404c7d96a268082d6a4cd2f6250ec1d1a0e5d27 Mon Sep 17 00:00:00 2001 From: Matt Webb Date: Wed, 24 Sep 2014 18:20:44 +0100 Subject: [PATCH] reorganising to show what the core is --- app/__init__.py | 4 ++-- app/core/__init__.py | 0 app/{ => core}/claiming.py | 2 +- app/{ => core}/commands.py | 6 +++--- app/{ => core}/crc16.py | 0 app/{ => core}/events.py | 0 app/{ => core}/payload.py | 0 app/models/__init__.py | 0 app/{models.py => models/core.py} | 2 +- 9 files changed, 7 insertions(+), 7 deletions(-) create mode 100644 app/core/__init__.py rename app/{ => core}/claiming.py (99%) rename app/{ => core}/commands.py (96%) rename app/{ => core}/crc16.py (100%) rename app/{ => core}/events.py (100%) rename app/{ => core}/payload.py (100%) create mode 100644 app/models/__init__.py rename app/{models.py => models/core.py} (99%) diff --git a/app/__init__.py b/app/__init__.py index 05ab4fb..e074577 100755 --- a/app/__init__.py +++ b/app/__init__.py @@ -12,8 +12,8 @@ bootstrap = Bootstrap() db = SQLAlchemy() sockets = Sockets() -from . import commands -from events import process_event +from core import commands +from core.events import process_event # @TODO diff --git a/app/core/__init__.py b/app/core/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/app/claiming.py b/app/core/claiming.py similarity index 99% rename from app/claiming.py rename to app/core/claiming.py index a2a18a1..7c0680e 100755 --- a/app/claiming.py +++ b/app/core/claiming.py @@ -1,4 +1,4 @@ -from crc16 import crc16 +from .crc16 import crc16 from Crypto.Cipher import AES, XOR import struct diff --git a/app/commands.py b/app/core/commands.py similarity index 96% rename from app/commands.py rename to app/core/commands.py index 8e14ded..f7403ce 100644 --- a/app/commands.py +++ b/app/core/commands.py @@ -1,6 +1,6 @@ -from .models import BridgeCommand -from .models import DeviceCommand -from .image_encoding import rle_image +from ..models.core import BridgeCommand +from ..models.core import DeviceCommand +from ..image_encoding import rle_image from .claiming import process_claim_code diff --git a/app/crc16.py b/app/core/crc16.py similarity index 100% rename from app/crc16.py rename to app/core/crc16.py diff --git a/app/events.py b/app/core/events.py similarity index 100% rename from app/events.py rename to app/core/events.py diff --git a/app/payload.py b/app/core/payload.py similarity index 100% rename from app/payload.py rename to app/core/payload.py diff --git a/app/models/__init__.py b/app/models/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/app/models.py b/app/models/core.py similarity index 99% rename from app/models.py rename to app/models/core.py index df3ed84..a11a7fb 100755 --- a/app/models.py +++ b/app/models/core.py @@ -1,4 +1,4 @@ -from . import db +from .. import db import json -- 2.47.3