Packaging the tool/library makes it easier for people to install and use. Poetry has some rough edges, but also some advantages, as it centralizes a lot in the pyproject.toml file.
The rough steps to go from the previous version of the repo to a Poetry package are as follows:
I created a src/roseingrave folder and did git mv *.py src/roseingrave/ to move the source files into a subfolder.
I created a pyproject.toml file.
I did poetry install to create a virtual environment for Poetry.
I looped over the packages in requirements.txt to add them with Poetry one-by-one with poetry add <package>
I added a section to poetry for the script entry point:
Packaging the tool/library makes it easier for people to install and use. Poetry has some rough edges, but also some advantages, as it centralizes a lot in the
pyproject.toml
file.The rough steps to go from the previous version of the repo to a Poetry package are as follows:
src/roseingrave
folder and didgit mv *.py src/roseingrave/
to move the source files into a subfolder.pyproject.toml
file.poetry install
to create a virtual environment for Poetry.requirements.txt
to add them with Poetry one-by-one withpoetry add <package>
defaults
subfolder)poetry publish --build
The package is here: https://pypi.org/project/roseingrave/