commit a47c52d8adee750b2496a0bb8ad998bf6d54c511 Author: Thomas Lindner Date: Tue Nov 16 00:56:58 2021 +0100 basic python package diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..b631813 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,10 @@ +root = true + +[*] +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true +charset = utf-8 +indent_style = space +indent_size = 4 +max_line_length = 88 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..7c463ec --- /dev/null +++ b/.gitignore @@ -0,0 +1,6 @@ +*.swp +*.egg-info/ +__pycache__/ +/.tox/ +/build/ +/venv/ diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..12b9019 --- /dev/null +++ b/LICENSE @@ -0,0 +1,13 @@ +Copyright (c) 2021 Thomas Lindner + +Permission to use, copy, modify, and distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..de33949 --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# Basic python package + +[lookatit](https://packaging.python.org/tutorials/packaging-projects/) diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..374b58c --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,6 @@ +[build-system] +requires = [ + "setuptools>=42", + "wheel" +] +build-backend = "setuptools.build_meta" diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 0000000..1b3685b --- /dev/null +++ b/setup.cfg @@ -0,0 +1,52 @@ +[metadata] +name = basicpy +version = 0.0.1 +author = Thomas Lindner +author_email = tom@dl6tom.de +description = Basic python package +long_description = file: README.md +long_description_content_type = text/markdown +url = https://git.0x90.space/vmann/basicpy +project_urls = + Bug Tracker = https://git.0x90.space/vmann/basicpy/issues +classifiers = + Programming Language :: Python :: 3 + License :: OSI Approved :: ISC License (ISCL) + Operating System :: OS Independent + +[options] +package_dir = + = src +packages = find: +python_requires = >=3.8 +#install_requires = +# dependency + +[options.packages.find] +where = src + +[options.entry_points] +console_scripts = + basicpy = basicpy:main + +[tox:tox] +envlist = py38, flake8, black, pytest +isolated_build = True + +[testenv:flake8] +deps = flake8 +commands = + flake8 src tests + +[testenv:black] +deps = black +commands = + black --check --diff src tests + +[testenv:pytest] +deps = pytest +commands = + pytest tests + +[flake8] +max_line_length = 88 diff --git a/src/basicpy/__init__.py b/src/basicpy/__init__.py new file mode 100644 index 0000000..5db74f3 --- /dev/null +++ b/src/basicpy/__init__.py @@ -0,0 +1,2 @@ +def main(): + print("Hello World") diff --git a/src/basicpy/__main__.py b/src/basicpy/__main__.py new file mode 100644 index 0000000..8273c4f --- /dev/null +++ b/src/basicpy/__main__.py @@ -0,0 +1,3 @@ +from . import main + +main() diff --git a/tests/test_basicpy.py b/tests/test_basicpy.py new file mode 100644 index 0000000..94e5242 --- /dev/null +++ b/tests/test_basicpy.py @@ -0,0 +1,2 @@ +def test_basicpy(): + pass