Skip to content

Commit eb7fccc

Browse files
committed
feat(ci): update ci publish pipeline
1 parent 81890af commit eb7fccc

File tree

2 files changed

+42
-33
lines changed

2 files changed

+42
-33
lines changed

.github/workflows/publish.yaml

-33
This file was deleted.

.github/workflows/python-sdk-ci.yaml

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: python-sdk-ci
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
tags:
7+
- '*'
8+
pull_request:
9+
branches: [ main ]
10+
11+
permissions:
12+
contents: write
13+
14+
jobs:
15+
build:
16+
name: Build
17+
runs-on: ubuntu-latest
18+
steps:
19+
- name: Checkout
20+
uses: actions/checkout@v3
21+
22+
- name: Setup Python
23+
uses: actions/setup-python@v4
24+
with:
25+
python-version: '3.11'
26+
27+
- name: Setup Dependencies
28+
run: |
29+
python -m pip install poetry
30+
poetry install
31+
poetry config pypi-token.pypi ${{ secrets.PYPI_TOKEN }}
32+
33+
- name: Build
34+
run: poetry build
35+
36+
- name: Publish
37+
if: startsWith(github.ref, 'refs/tags/')
38+
run: poetry publish
39+
40+
- name: Release
41+
if: startsWith(github.ref, 'refs/tags/')
42+
uses: softprops/action-gh-release@v1

0 commit comments

Comments
 (0)