Skip to content

Commit cc705b0

Browse files
authored
Move to tox4 and pure pyproject packaging (#11)
(DIS-1750)
1 parent 916a6ee commit cc705b0

File tree

5 files changed

+60
-60
lines changed

5 files changed

+60
-60
lines changed

MANIFEST.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
exclude .gitignore
2-
exclude .github
2+
recursive-exclude .github/ *

pyproject.toml

Lines changed: 31 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,29 @@
11
[build-system]
2-
requires = ["setuptools>=43.0.0", "wheel", "setuptools_scm[toml]>=3.4.1"]
2+
requires = ["setuptools>=65.5.0", "setuptools_scm[toml]>=6.4.0"]
33
build-backend = "setuptools.build_meta"
44

5-
[tool.setuptools_scm]
5+
[project]
6+
name = "dissect.eventlog"
7+
description = "A Dissect module implementing parsers for the Windows EVT, EVTX and WEVT log file formats"
8+
readme = "README.md"
9+
requires-python = "~=3.9"
10+
license.text = "Affero General Public License v3"
11+
authors = [
12+
{name = "Dissect Team", email = "[email protected]"}
13+
]
14+
classifiers = [
15+
"Programming Language :: Python :: 3",
16+
]
17+
dependencies = [
18+
"dissect.cstruct>=3.0.dev,<4.0.dev",
19+
"dissect.util>=3.0.dev,<4.0.dev",
20+
]
21+
dynamic = ["version"]
22+
23+
[project.urls]
24+
homepage = "https://dissect.tools"
25+
documentation = "https://docs.dissect.tools/en/latest/projects/dissect.eventlog"
26+
repository = "https://github.com/fox-it/dissect.eventlog"
627

728
[tool.black]
829
line-length = 120
@@ -11,3 +32,11 @@ line-length = 120
1132
profile = "black"
1233
known_first_party = ["dissect.eventlog"]
1334
known_third_party = ["dissect"]
35+
36+
[tool.setuptools]
37+
license-files = ["LICENSE", "COPYRIGHT"]
38+
39+
[tool.setuptools.packages.find]
40+
include = ["dissect.*"]
41+
42+
[tool.setuptools_scm]

setup.cfg

Lines changed: 0 additions & 14 deletions
This file was deleted.

setup.py

Lines changed: 0 additions & 10 deletions
This file was deleted.

tox.ini

Lines changed: 28 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,14 @@
11
[tox]
22
envlist = lint, py3, pypy3
33
# This version of tox will autoprovision itself and the requirements defined in
4-
# requires if they are not available on the host system.
5-
minversion = 3.8.0
6-
# This version of virtualenv installs a pip version of at least 19.0.1 in its
7-
# venvs.
8-
# Requiring minimally this version of virtualenv to be available prevents the
9-
# need of having to explicitly specify a pip>=19.0 dependency in every testenv.
10-
# pip>=19.0 is needed to ensure the sdist build by tox (which is build
11-
# according to PEP 517 and PEP 518 by tox versions >= 3.4.0) is also installed
12-
# properly (according to PEP 517 and PEP 518 by pip>=19.0) in the virtualenvs.
13-
# If the dependency is not available on the host system, and the installed tox
14-
# version is >= 3.3.0, tox will self bootstrap an environment with the proper
15-
# versions (including the version of tox itself).
16-
requires = virtualenv>=16.3.0
17-
isolated_build = true
18-
# Putting the dist dir in the project directory instead of in the {toxworkdir},
19-
# makes the sdist more easily accesible and prevents the need of rebuilding it
20-
# for the [testenv:build] target.
21-
distdir = {toxinidir}/dist
4+
# requires if they are not available on the host system. This requires the
5+
# locally installed tox to have a minimum version 3.3.0. This means the names
6+
# of the configuration options are still according to the tox 3.x syntax.
7+
minversion = 4.2.4
8+
# This version of virtualenv will install setuptools version 65.5.0 and pip
9+
# 22.3. These versions fully support python projects defined only through a
10+
# pyproject.toml file (PEP-517/PEP-518/PEP-621)
11+
requires = virtualenv>=20.16.6
2212

2313
[testenv]
2414
deps =
@@ -30,29 +20,34 @@ commands =
3020
coverage report
3121
coverage xml
3222

23+
[testenv:build]
24+
package = skip
25+
deps =
26+
build
27+
commands =
28+
pyproject-build
29+
30+
[testenv:fix]
31+
package = skip
32+
deps =
33+
black==23.1.0
34+
isort==5.11.4
35+
commands =
36+
black dissect tests
37+
isort dissect tests
38+
3339
[testenv:lint]
34-
# Force the Python version here, so linting will be done with the correct
35-
# Python version. There should be no difference between the CPython and pypy
36-
# implementations, so we pick one.
37-
basepython = python3
40+
package = skip
3841
deps =
3942
black==23.1.0
4043
flake8
4144
flake8-black
4245
flake8-isort
46+
isort==5.11.4
4347
vermin
4448
commands =
45-
flake8 dissect tests setup.py
46-
vermin -t=3.9- --no-tips --lint dissect tests setup.py
47-
48-
[testenv:build]
49-
# Force the Python version here, so building will be done with the correct
50-
# Python version. As the distributions are pure Python, there should be no
51-
# difference between the CPython and pypy implementations, so we pick one.
52-
basepython = python3
53-
deps =
54-
commands =
55-
pip wheel --no-deps -w ./dist .
49+
flake8 dissect tests
50+
vermin -t=3.9- --no-tips --lint dissect tests
5651

5752
[flake8]
5853
max-line-length = 120

0 commit comments

Comments
 (0)