diff --git a/src/__init__.py b/kcidev/__init__.py similarity index 100% rename from src/__init__.py rename to kcidev/__init__.py diff --git a/src/libs/__init__.py b/kcidev/libs/__init__.py similarity index 100% rename from src/libs/__init__.py rename to kcidev/libs/__init__.py diff --git a/src/libs/common.py b/kcidev/libs/common.py similarity index 100% rename from src/libs/common.py rename to kcidev/libs/common.py diff --git a/src/kcidev.py b/kcidev/main.py similarity index 91% rename from src/kcidev.py rename to kcidev/main.py index 8afc15f..c38e856 100755 --- a/src/kcidev.py +++ b/kcidev/main.py @@ -3,8 +3,8 @@ import click -from libs.common import * -from subcommands import checkout, commit, patch, results, testretry +from kcidev.libs.common import * +from kcidev.subcommands import checkout, commit, patch, results, testretry @click.group( diff --git a/src/subcommands/__init__.py b/kcidev/subcommands/__init__.py similarity index 100% rename from src/subcommands/__init__.py rename to kcidev/subcommands/__init__.py diff --git a/src/subcommands/checkout.py b/kcidev/subcommands/checkout.py similarity index 99% rename from src/subcommands/checkout.py rename to kcidev/subcommands/checkout.py index 7ed90e4..4e011bc 100644 --- a/src/subcommands/checkout.py +++ b/kcidev/subcommands/checkout.py @@ -12,7 +12,7 @@ import requests from git import Repo -from libs.common import * +from kcidev.libs.common import * def api_connection(host): diff --git a/src/subcommands/commit.py b/kcidev/subcommands/commit.py similarity index 100% rename from src/subcommands/commit.py rename to kcidev/subcommands/commit.py diff --git a/src/subcommands/patch.py b/kcidev/subcommands/patch.py similarity index 100% rename from src/subcommands/patch.py rename to kcidev/subcommands/patch.py diff --git a/src/subcommands/results.py b/kcidev/subcommands/results.py similarity index 100% rename from src/subcommands/results.py rename to kcidev/subcommands/results.py diff --git a/src/subcommands/testretry.py b/kcidev/subcommands/testretry.py similarity index 98% rename from src/subcommands/testretry.py rename to kcidev/subcommands/testretry.py index aee8df5..f6a46ae 100644 --- a/src/subcommands/testretry.py +++ b/kcidev/subcommands/testretry.py @@ -7,7 +7,7 @@ import requests from git import Repo -from libs.common import * +from kcidev.libs.common import * def api_connection(host): diff --git a/pyproject.toml b/pyproject.toml index 67b7cec..3312f1e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -6,12 +6,13 @@ authors = ["Arisu Tachibana "] license = "LGPL-2.1-or-later" readme = "README.md" packages = [ -{include = "src"}, -{include = "subcommands", from="src"}, +{include = "kcidev"}, +{include = "subcommands", from="kcidev"}, +{include = "libs", from="kcidev"}, ] repository = "https://github.com/kernelci/kci-dev" classifiers = [ - 'Development Status :: 4 - beta', + 'Development Status :: 4 - Beta', 'Environment :: Console', 'Intended Audience :: Developers', 'Operating System :: OS Independent', @@ -34,7 +35,7 @@ toml = "^0.10.2" gitpython = "^3.1.43" [tool.poetry.scripts] -kci-dev = 'src.kcidev:run' +kci-dev = 'kcidev.main:run' [tool.poetry.urls] "Issue Tracker" = "https://github.com/kernelci/kci-dev/issues" diff --git a/tests/test_kcidev.py b/tests/test_kcidev.py index 3fb7bae..989e24f 100644 --- a/tests/test_kcidev.py +++ b/tests/test_kcidev.py @@ -139,7 +139,7 @@ def test_kcidev_commit(): def test_main(): - from subcommands.commit import api_connection + from kcidev.subcommands.commit import api_connection print(api_connection("test"))