From 81718c5b6aa6f6fc9221e6e4e692b80955946475 Mon Sep 17 00:00:00 2001 From: Roman Mogylatov Date: Thu, 21 Dec 2017 22:06:00 +0200 Subject: [PATCH] Rename bundles example --- examples/miniapps/applications/example/core/__init__.py | 0 examples/miniapps/bundles/README.rst | 8 ++++++++ examples/miniapps/bundles/bundles/__init__.py | 1 + .../example => bundles/bundles}/photos/__init__.py | 4 ++-- .../example => bundles/bundles}/photos/entities.py | 0 .../example => bundles/bundles}/photos/repositories.py | 0 .../example => bundles/bundles}/users/__init__.py | 4 ++-- .../example => bundles/bundles}/users/entities.py | 0 .../example => bundles/bundles}/users/repositories.py | 0 .../{applications/example => bundles/core}/__init__.py | 0 .../{applications/example => bundles}/core/containers.py | 0 .../{applications/example => bundles}/core/providers.py | 0 .../{applications/example/main.py => bundles/run.py} | 6 +++--- 13 files changed, 16 insertions(+), 7 deletions(-) delete mode 100644 examples/miniapps/applications/example/core/__init__.py create mode 100644 examples/miniapps/bundles/README.rst create mode 100644 examples/miniapps/bundles/bundles/__init__.py rename examples/miniapps/{applications/example => bundles/bundles}/photos/__init__.py (90%) rename examples/miniapps/{applications/example => bundles/bundles}/photos/entities.py (100%) rename examples/miniapps/{applications/example => bundles/bundles}/photos/repositories.py (100%) rename examples/miniapps/{applications/example => bundles/bundles}/users/__init__.py (89%) rename examples/miniapps/{applications/example => bundles/bundles}/users/entities.py (100%) rename examples/miniapps/{applications/example => bundles/bundles}/users/repositories.py (100%) rename examples/miniapps/{applications/example => bundles/core}/__init__.py (100%) rename examples/miniapps/{applications/example => bundles}/core/containers.py (100%) rename examples/miniapps/{applications/example => bundles}/core/providers.py (100%) rename examples/miniapps/{applications/example/main.py => bundles/run.py} (86%) diff --git a/examples/miniapps/applications/example/core/__init__.py b/examples/miniapps/applications/example/core/__init__.py deleted file mode 100644 index e69de29b..00000000 diff --git a/examples/miniapps/bundles/README.rst b/examples/miniapps/bundles/README.rst new file mode 100644 index 00000000..a794d4b5 --- /dev/null +++ b/examples/miniapps/bundles/README.rst @@ -0,0 +1,8 @@ +Dependency Injector Bundles example +=================================== + +Instructions for running + +.. code-block:: bash + + python run.py diff --git a/examples/miniapps/bundles/bundles/__init__.py b/examples/miniapps/bundles/bundles/__init__.py new file mode 100644 index 00000000..de248351 --- /dev/null +++ b/examples/miniapps/bundles/bundles/__init__.py @@ -0,0 +1 @@ +"""Bundles package.""" diff --git a/examples/miniapps/applications/example/photos/__init__.py b/examples/miniapps/bundles/bundles/photos/__init__.py similarity index 90% rename from examples/miniapps/applications/example/photos/__init__.py rename to examples/miniapps/bundles/bundles/photos/__init__.py index 63bf442a..5c9e0c50 100644 --- a/examples/miniapps/applications/example/photos/__init__.py +++ b/examples/miniapps/bundles/bundles/photos/__init__.py @@ -1,4 +1,4 @@ -"""Photos package.""" +"""Photos bundle.""" from core import containers from core import providers @@ -8,7 +8,7 @@ from . import repositories class Photos(containers.DeclarativeContainer): - """Photos package container.""" + """Photos bundle container.""" database = providers.Dependency() file_storage = providers.Dependency() diff --git a/examples/miniapps/applications/example/photos/entities.py b/examples/miniapps/bundles/bundles/photos/entities.py similarity index 100% rename from examples/miniapps/applications/example/photos/entities.py rename to examples/miniapps/bundles/bundles/photos/entities.py diff --git a/examples/miniapps/applications/example/photos/repositories.py b/examples/miniapps/bundles/bundles/photos/repositories.py similarity index 100% rename from examples/miniapps/applications/example/photos/repositories.py rename to examples/miniapps/bundles/bundles/photos/repositories.py diff --git a/examples/miniapps/applications/example/users/__init__.py b/examples/miniapps/bundles/bundles/users/__init__.py similarity index 89% rename from examples/miniapps/applications/example/users/__init__.py rename to examples/miniapps/bundles/bundles/users/__init__.py index af0898d8..ebd57c33 100644 --- a/examples/miniapps/applications/example/users/__init__.py +++ b/examples/miniapps/bundles/bundles/users/__init__.py @@ -1,4 +1,4 @@ -"""Users package.""" +"""Users bundle.""" from core import containers from core import providers @@ -8,7 +8,7 @@ from . import repositories class Users(containers.DeclarativeContainer): - """Users container.""" + """Users bundle container.""" database = providers.Dependency() diff --git a/examples/miniapps/applications/example/users/entities.py b/examples/miniapps/bundles/bundles/users/entities.py similarity index 100% rename from examples/miniapps/applications/example/users/entities.py rename to examples/miniapps/bundles/bundles/users/entities.py diff --git a/examples/miniapps/applications/example/users/repositories.py b/examples/miniapps/bundles/bundles/users/repositories.py similarity index 100% rename from examples/miniapps/applications/example/users/repositories.py rename to examples/miniapps/bundles/bundles/users/repositories.py diff --git a/examples/miniapps/applications/example/__init__.py b/examples/miniapps/bundles/core/__init__.py similarity index 100% rename from examples/miniapps/applications/example/__init__.py rename to examples/miniapps/bundles/core/__init__.py diff --git a/examples/miniapps/applications/example/core/containers.py b/examples/miniapps/bundles/core/containers.py similarity index 100% rename from examples/miniapps/applications/example/core/containers.py rename to examples/miniapps/bundles/core/containers.py diff --git a/examples/miniapps/applications/example/core/providers.py b/examples/miniapps/bundles/core/providers.py similarity index 100% rename from examples/miniapps/applications/example/core/providers.py rename to examples/miniapps/bundles/core/providers.py diff --git a/examples/miniapps/applications/example/main.py b/examples/miniapps/bundles/run.py similarity index 86% rename from examples/miniapps/applications/example/main.py rename to examples/miniapps/bundles/run.py index d2cfb23a..dafb8db0 100644 --- a/examples/miniapps/applications/example/main.py +++ b/examples/miniapps/bundles/run.py @@ -1,9 +1,9 @@ -"""Example applications.""" +"""Example application - Bundles.""" from core import containers, providers -from users import Users -from photos import Photos +from bundles.users import Users +from bundles.photos import Photos class Core(containers.DeclarativeContainer):