Open dave-doty opened 3 years ago
Note that this is a bit of a pain to set up because packages can only be published to PyPI if they increment the version number, so you need to set up some way to track the version.
I do it in scadnano with a top-level variable in my main python file (like https://github.com/UC-Davis-molecular-computing/population-protocols-python-package/blob/main/ppsim/ppsim.py here):
There's some ugly code in both setup.py (https://github.com/UC-Davis-molecular-computing/scadnano-python-package/blob/master/setup.py, for PyPI) and doc/conf.py (https://github.com/UC-Davis-molecular-computing/scadnano-python-package/blob/master/doc/conf.py, for sphinx to generate API documentation), so that they both only read the official version number from one place.
See here for example:
https://github.com/UC-Davis-molecular-computing/scadnano-python-package/blob/b6cd6984c66e766b20b5a7a34654d3ca3fba42bf/.github/workflows/release.yml#L27-L43