Commit ff5420c
committed
Convert to trusted publishing
I based this change on the official PyPI documentation:
https://docs.pypi.org/trusted-publishers/
as well as a blog post walking through an example of how to implement
trusted publishing for a Python project:
https://pgjones.dev/blog/trusted-plublishing-2023/
The diff is fairly minimal. All it does is remove the password used to
authenticate to PyPI, which we don't need anymore, and add a permission
needed for trusted publishing to operate.
This commit will be accompanied by some configuration in the project
settings on PyPI to allow this specific workflow to act as a trusted
publisher. Effectively, we're telling PyPI that when this particular
workflow (`publish.yml`) contacts it with an OIDC token from Github,
then PyPI should accept that as valid authentication and return an API
token which can be used to actually upload a package.1 parent e6baa2f commit ff5420c
1 file changed
+6
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
34 | 37 | | |
35 | 38 | | |
36 | 39 | | |
| |||
39 | 42 | | |
40 | 43 | | |
41 | 44 | | |
42 | | - | |
43 | 45 | | |
44 | 46 | | |
45 | 47 | | |
46 | 48 | | |
47 | 49 | | |
48 | 50 | | |
49 | 51 | | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
50 | 55 | | |
51 | 56 | | |
52 | 57 | | |
| |||
55 | 60 | | |
56 | 61 | | |
57 | 62 | | |
58 | | - | |
59 | 63 | | |
0 commit comments