Skip to content

Commit a4d8f74

Browse files
committed
Added workflow to publish on PyPI
1 parent eca65df commit a4d8f74

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# Copyright 2025 StreamNative, Inc.
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
name: Publish to PyPI
16+
17+
on:
18+
push:
19+
tags:
20+
- v*
21+
22+
jobs:
23+
build_and_publish:
24+
runs-on: ubuntu-latest
25+
environment: pypi # Optional: use a GitHub environment for added security
26+
permissions:
27+
id-token: write # Required for OIDC authentication
28+
contents: read # Required to checkout the repository
29+
30+
steps:
31+
- name: Checkout repository
32+
uses: actions/checkout@v5
33+
34+
- name: Install uv
35+
uses: astral-sh/setup-uv@v6
36+
37+
- name: Install Python
38+
run: uv python install 3.13
39+
40+
- name: Build distribution packages
41+
run: uv build
42+
43+
- name: Publish package to PyPI
44+
run: uv publish

0 commit comments

Comments
 (0)