Skip to content

Commit

Permalink
use project.scripts instead of tool.poetry.scripts for entrypoints
Browse files Browse the repository at this point in the history
After the change from poetry to pdm in #121, it appears that some build systems
have trouble groking what scripts to install due to the use of the
poetry-specific entrypoint configuration in pyproject.toml.

This change updates the pyproject.toml to use the
[PEP-621](https://www.python.org/dev/peps/pep-0621) specification for
identifying console_scripts/entrypoints, and resolves the build issue on
Fedora. From my testing, there is no impact for installations via e.g.
`pip`, as these tools will understand PEP-621 entrypoint specifications.
  • Loading branch information
NeilHanlon authored and supakeen committed Oct 28, 2023
1 parent 575532e commit 7868b4b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ dev = [
requires = ["pdm-pep517>=1.0"]
build-backend = "pdm.pep517.api"

[project.scripts]
pinnwand = 'pinnwand.__main__:main'

[tool.black]
line-length = 80
target_version = ["py36"]
Expand All @@ -63,8 +66,6 @@ exclude = '''
| dist
)/
'''
[tool.poetry.scripts]
pinnwand = 'pinnwand.__main__:main'

[tool.pytest.ini_options]
pythonpath = ["src"]
Expand Down

0 comments on commit 7868b4b

Please sign in to comment.