Skip to content

Commit df4291d

Browse files
authored
Adopt src code layout (#116)
1 parent 94a2b0f commit df4291d

File tree

6 files changed

+12
-6
lines changed

6 files changed

+12
-6
lines changed

setup.cfg

+6-6
Original file line numberDiff line numberDiff line change
@@ -30,18 +30,18 @@ keywords =
3030
[options]
3131
use_scm_version = True
3232
python_requires = >=3.8
33-
; package_dir =
34-
; = src
35-
; packages = find:
36-
37-
; [options.packages.find]
38-
; where = src
33+
package_dir =
34+
= src
35+
packages = find:
3936

4037
[options.extras_require]
4138
test =
4239
coverage>=6.3
4340
pytest-cov>=3.0.0
4441
pytest>=7.0.0
4542

43+
[options.packages.find]
44+
where = src
45+
4646
[options.package_data]
4747
vagrant = py.typed
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

tox.ini

+6
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,8 @@ deps =
5555
skip_install = true
5656
# Ref: https://twitter.com/di_codes/status/1044358639081975813
5757
commands =
58+
# Safety measure to remove library if somehow appears as installed
59+
sh -c "pip uninstall -y python-vagrant 2>/dev/null"
5860
# build wheel and sdist using PEP-517
5961
{envpython} -c 'import os.path, shutil, sys; \
6062
dist_dir = os.path.join("{toxinidir}", "dist"); \
@@ -68,3 +70,7 @@ commands =
6870
twine check --strict {toxinidir}/dist/*
6971
# Install the wheel
7072
sh -c "python3 -m pip install {toxinidir}/dist/*.whl"
73+
# Basic checks
74+
python -c "import sys, pkgutil; sys.exit(0 if pkgutil.find_loader(sys.argv[1]) else 1)" vagrant
75+
# Uninstall the wheel
76+
pip uninstall -y python-vagrant

0 commit comments

Comments
 (0)