Skip to content

Commit

Permalink
Move to src/ layout (#364)
Browse files Browse the repository at this point in the history
  • Loading branch information
tony authored Sep 11, 2022
2 parents 0cea451 + a1c9535 commit b4f9e0e
Show file tree
Hide file tree
Showing 8 changed files with 7 additions and 5 deletions.
5 changes: 3 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,14 @@
# Get the project root dir, which is the parent dir of this
cwd = Path(__file__).parent
project_root = cwd.parent
src_root = project_root / "src"

sys.path.insert(0, str(project_root))
sys.path.insert(0, str(src_root))
sys.path.insert(0, str(cwd / "_ext"))

# package data
about: t.Dict[str, str] = {}
with open(project_root / "django_slugify_processor" / "__about__.py") as fp:
with open(src_root / "django_slugify_processor" / "__about__.py") as fp:
exec(fp.read(), about)

extensions = [
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ authors = [

readme = 'README.md'
packages = [
{ include = "django_slugify_processor" },
{ include = "*", from = "src" },
]
include = [
{ path = "tests", format = "sdist" },
Expand Down
5 changes: 3 additions & 2 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
inline-quotes = single
max-line-length = 100
max-complexity = 10
exclude = .*/,*.egg,django_slugify_processors/__*__.py,
exclude = .*/,*.egg,src/django_slugify_processors/__*__.py,
select = E,W,F,N
# Stuff we ignore thanks to black: https://github.com/ambv/black/issues/429
extend-ignore = E203,W503
Expand All @@ -26,6 +26,7 @@ doctest_optionflags = ELLIPSIS NORMALIZE_WHITESPACE
django_find_project = false
DJANGO_SETTINGS_MODULE = tests.settings
testpaths =
django_slugify_processor
src/django_slugify_processor
tests
docs
pythonpath = . tests
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit b4f9e0e

Please sign in to comment.