diff --git a/.envrc b/.envrc deleted file mode 100644 index 1b51213..0000000 --- a/.envrc +++ /dev/null @@ -1,5 +0,0 @@ -export PYTHONDEVMODE=1 -export VIRTUAL_ENV=.venv -layout python3 -export DJANGO_SETTINGS_MODULE=dx.settings -export DJANGO_CONFIGURATION=Local diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml deleted file mode 100644 index 4dd1b78..0000000 --- a/.pre-commit-config.yaml +++ /dev/null @@ -1,4 +0,0 @@ -- repo: https://github.com/peterdemin/pip-compile-multi - rev: v2.6.2 - hooks: - - id: pip-compile-multi-verify diff --git a/justfile b/justfile deleted file mode 100644 index 3fe2aed..0000000 --- a/justfile +++ /dev/null @@ -1,24 +0,0 @@ -default: test - -alias tc := test-coverage -alias l := lint -alias lf := lint-fix -alias c := compile-dependencies - -test: - # pytest options can be found in pyproject.toml - # look for [tool.pytest.ini_options] - python -m pytest - -test-coverage: - # here we allow extra arguments to be passed to pytest - python -m pytest --cov=src --cov-config=pyproject.toml - -lint: - ruff check . - -lint-fix: - ruff check --fix . - -compile-dependencies: - pip-compile-multi diff --git a/pyproject.toml b/pyproject.toml index c17d348..e87510d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,16 +13,3 @@ build-backend = "hatchling.build" [tool.pytest.ini_options] pythonpath = ["src"] -testpaths = ["tests"] - -[tool.coverage.run] -branch = true -data_file = "coverage/.coverage" -source = ["src"] -omit = ["*/migrations/*"] - -[tool.coverage.html] -directory = "coverage/htmlcov" - -[tool.coverage.report] -skip_empty = true diff --git a/requirements/base.in b/requirements/base.in index 797b722..54d157a 100644 --- a/requirements/base.in +++ b/requirements/base.in @@ -1,3 +1,2 @@ -django-configurations django>=5.1,<5.2 pip-lock diff --git a/requirements/base.txt b/requirements/base.txt index 3ea6a65..66a8864 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -1,4 +1,4 @@ -# SHA1:78e037786a8e05baa81b92ef0373bd8fc1069bd9 +# SHA1:e1677d1f2cf78dc26b96c6f8b02f0a0192f1d402 # # This file is autogenerated by pip-compile-multi # To update, run: @@ -8,10 +8,6 @@ asgiref==3.8.1 # via django django==5.1.3 - # via - # -r requirements/base.in - # django-configurations -django-configurations==2.5.1 # via -r requirements/base.in pip-lock==2.12.0 # via -r requirements/base.in diff --git a/src/dx/__init__.py b/src/dx/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/src/dx/settings.py b/src/dx/settings.py deleted file mode 100644 index 2ff9590..0000000 --- a/src/dx/settings.py +++ /dev/null @@ -1,39 +0,0 @@ -from pathlib import Path -from configurations import Configuration - -BASE_DIR = Path(__file__).resolve().parent.parent - - -class Base(Configuration): - DEBUG = False - DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField" - INSTALLED_APPS = [ - "dx", - ] - ROOT_URLCONF = "dx.urls" - SECRET_KEY = "django-insecure-cbgvn=orgh$&6l-w91pp2=(b#hjwe1z&ijwiafgt(py1lq5i85" - TEMPLATES = [ - { - "BACKEND": "django.template.backends.django.DjangoTemplates", - "DIRS": [BASE_DIR / "templates"], - "APP_DIRS": True, - }, - ] - USE_TZ = True - - -class Dev(Base): - # Dangerous: disable host header validation - ALLOWED_HOSTS = ["*"] - DATABASES = { - "default": { - "ENGINE": "django.db.backends.sqlite3", - "NAME": "db.sqlite3", - }, - } - DEBUG = True - INSTALLED_APPS = Base.INSTALLED_APPS + ["django_extensions"] - - -class Local(Dev): - pass diff --git a/src/dx/urls.py b/src/dx/urls.py deleted file mode 100644 index 637600f..0000000 --- a/src/dx/urls.py +++ /dev/null @@ -1 +0,0 @@ -urlpatterns = [] diff --git a/src/foo.py b/src/foo.py deleted file mode 100644 index 7dbdb99..0000000 --- a/src/foo.py +++ /dev/null @@ -1,2 +0,0 @@ -def dummy(): - return (1, 1, 1) diff --git a/src/manage.py b/src/manage.py deleted file mode 100755 index 22d839f..0000000 --- a/src/manage.py +++ /dev/null @@ -1,18 +0,0 @@ -#!/usr/bin/env python -"""Django's command-line utility for administrative tasks.""" - -import os -import sys - - -def main(): - os.environ.setdefault("DJANGO_SETTINGS_MODULE", "dx.settings") - os.environ.setdefault("DJANGO_CONFIGURATION", "Base") - - from configurations.management import execute_from_command_line - - execute_from_command_line(sys.argv) - - -if __name__ == "__main__": - main() diff --git a/tests/test_something.py b/tests/test_something.py deleted file mode 100644 index c448d64..0000000 --- a/tests/test_something.py +++ /dev/null @@ -1,8 +0,0 @@ -def test_always_true(): - assert True - - -def test_something_in_src(): - from foo import dummy - - assert dummy() == (1, 1, 1)