-
Notifications
You must be signed in to change notification settings - Fork 186
Closed
Labels
type: choreChanges to the build process or auxiliary tools and libraries such as documentation generationChanges to the build process or auxiliary tools and libraries such as documentation generation
Description
Problem
In looking into #309, I see that scripts
are being used. These are troublesome for cross-platform downstreams, as they make otherwise-well-behaved distributions less portable.
Proposal
Migrate from scripts
to entry_points
, where:
- the contents of
scripts/gql-cli
would be move togql/cli.py
- as
main
is already named there, might have a different name, e.g.entry_point_main
- as
setup.py
would be updated, a la:
--- setup.py 2022-03-25 11:06:08.397539455 -0500
+++ setup.py 2022-03-25 11:08:23.321126291 -0500
@@ -8,7 +8,7 @@
]
scripts = [
- "scripts/gql-cli",
+ "gql-cli=gli.cli:main"
]
tests_requires = [
@@ -106,5 +106,5 @@
include_package_data=True,
zip_safe=False,
platforms="any",
- scripts=scripts,
+ entry_points={"console_scripts": scripts}
)
This would also allow the noarch python wheels to be created, which would be helpful for performance and security without increasing the maintenance/build burden much.
Metadata
Metadata
Assignees
Labels
type: choreChanges to the build process or auxiliary tools and libraries such as documentation generationChanges to the build process or auxiliary tools and libraries such as documentation generation