Skip to content

Commit 7e45d0f

Browse files
authored
Merge pull request #153 from argyle-engineering/publish-pypi
Add workflow to publish Python package
2 parents eae0202 + 3dfd8df commit 7e45d0f

File tree

1 file changed

+39
-0
lines changed

1 file changed

+39
-0
lines changed
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Publish package to pypi.org
2+
3+
on:
4+
release:
5+
types:
6+
- published
7+
8+
jobs:
9+
pypi-publish:
10+
runs-on: ubuntu-22.04
11+
12+
environment:
13+
name: pypi
14+
url: https://test.pypi.org/p/pydantic2zod
15+
16+
permissions:
17+
id-token: write
18+
19+
steps:
20+
- uses: actions/checkout@v3.3.0
21+
22+
- uses: actions/setup-python@v4.5.0
23+
with:
24+
python-version: "3.10"
25+
26+
- uses: Gr1N/setup-poetry@v9
27+
with:
28+
poetry-version: "1.8.4"
29+
30+
- name: Install dependencies
31+
run: poetry install
32+
33+
- name: Build package
34+
run: poetry build
35+
36+
- name: Publish a package
37+
uses: pypa/gh-action-pypi-publish@release/v1
38+
with:
39+
verbose: true

0 commit comments

Comments
 (0)