linux-automation / lxa-iobus

Linux Automation IOBus server
https://lxa-iobus.readthedocs.io/en/latest/
Apache License 2.0
3 stars 4 forks source link

CI: add automatic publication to pypi.org and test.pypi.org #46

Closed hnez closed 4 months ago

hnez commented 4 months ago

Publishing software manually is a (somewhat) error-prone and (somewhat) tedious process, hence why other projects have already automated this process.

Let's join these other projects and also automate our publication process!

The setup process is surprisingly straight forward and involves setting up trusted publishing on both pypi.org, as well as test.pypi.org for the lxa-iobus project:

pypi-auto

And setting a GitHub Action Variable that enables publication (so that the job does not run and fail for forked repositories by default):

github-variable

TODO before merging:

Both of these PRs should be merged before this one.

hnez commented 4 months ago

I should mention that this PR is heavily inspired by @jluebbe's work over at pdudaemon/pdudaemon#155. I did however tweak a few aspects: