Skip to content

Commit 6ef6af1

Browse files
authored
docs: Document how to publish package to PyPI (#185)
1 parent 61b6f7d commit 6ef6af1

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

CONTRIBUTING.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,28 @@ poetry run sphinx-build docs docs/_build --builder html --fail-on-warning
8888
start docs\_build\index.html
8989
```
9090

91+
# Publishing on PyPI
92+
93+
You can publish the `nitypes` package by creating a GitHub release
94+
in the `nitypes-python` repo. Here are the steps to follow to publish the package:
95+
96+
1. From the main GitHub repo page, select "Create a new release".
97+
2. On the "New Release" page, create a new tag using the "Select Tag" drop down. The tag must be the package version, matching the
98+
value found in pyproject.toml. Example: `0.1.0-dev0`.
99+
3. Enter a title in the "Release title" field. The title should contain the package name and
100+
version in the format `nitypes <package-version>`. For example: `nitypes 0.1.0-dev0`.
101+
4. Click "Generate release notes" and edit the release notes.
102+
- Delete entries for PRs that do not affect users, such as "chore(deps):" and "fix(deps):" PRs.
103+
- Consider grouping related entries.
104+
- Reformat entries to be more readable. For example, change "Blah blah by so-and-so in \#123" to "Blah blah (\#123)".
105+
5. If this is a pre-release release, check the "Set as a pre-release" checkbox.
106+
6. Click "Publish release".
107+
7. Creating a release will start the publish workflow. You can track the
108+
progress of this workflow in the "Actions" page of the GitHub repo.
109+
8. The workflow job that publishes a package to PyPI requires code owner approval. This job will automatically send code owners a notification email, then it will wait for them to log in and approve the deployment.
110+
9. After receiving code owner approval, the publish workflow will resume.
111+
10. Once the publish workflow has finished, you should see your release on PyPI.
112+
91113
# Developer Certificate of Origin (DCO)
92114

93115
Developer's Certificate of Origin 1.1

0 commit comments

Comments
 (0)