Skip to content

Commit

Permalink
Defer to .txt files for requirements.
Browse files Browse the repository at this point in the history
These are easier for a user to read and/or install separately with pip.
  • Loading branch information
Gadgetoid committed Jun 27, 2024
1 parent dbae8f3 commit addcba5
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 11 deletions.
10 changes: 7 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[build-system]
requires = ["hatchling", "hatch-fancy-pypi-readme"]
requires = ["hatchling", "hatch-fancy-pypi-readme", "hatch-requirements-txt"]
build-backend = "hatchling.build"

[project]
name = "PROJECT_NAME"
dynamic = ["version", "readme"]
dynamic = ["version", "readme", "optional-dependencies"]
description = "__DESCRIPTION__"
license = {file = "LICENSE"}
requires-python = ">= 3.7"
Expand Down Expand Up @@ -36,6 +36,9 @@ classifiers = [
]
dependencies = []

[tool.hatch.metadata.hooks.requirements_txt.optional-dependencies]
example-depends = ["requirements-examples.txt"]

[project.urls]
GitHub = "https://www.github.com/pimoroni/PROJECT_NAME-python"
Homepage = "https://www.pimoroni.com"
Expand All @@ -48,7 +51,8 @@ include = [
"PROJECT_NAME",
"README.md",
"CHANGELOG.md",
"LICENSE"
"LICENSE",
"requirements-examples.txt"
]

[tool.hatch.build.targets.sdist]
Expand Down
1 change: 1 addition & 0 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@ isort
twine
hatch
hatch-fancy-pypi-readme
hatch-requirements-txt
tox
pdoc
Empty file added requirements-examples.txt
Empty file.
9 changes: 1 addition & 8 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,5 @@ commands =
ruff check .
codespell .
deps =
check-manifest
ruff
codespell
isort
twine
build
hatch
hatch-fancy-pypi-readme
-r{toxinidir}/requirements-dev.txt

0 comments on commit addcba5

Please sign in to comment.