Skip to content

Commit 48e282c

Browse files
committed
publish action
1 parent ce9603c commit 48e282c

1 file changed

Lines changed: 36 additions & 0 deletions

File tree

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Publish Python package
2+
3+
on:
4+
push:
5+
# Publish on version tags e.g. v1.2.3
6+
tags:
7+
- 'v*.*.*'
8+
workflow_dispatch:
9+
10+
jobs:
11+
publish:
12+
runs-on: ubuntu-latest
13+
permissions:
14+
id-token: write
15+
steps:
16+
- name: Check out code
17+
uses: actions/checkout@v3
18+
19+
- name: Set up Python
20+
uses: actions/setup-python@v4
21+
with:
22+
python-version: '3.x'
23+
24+
- name: Install build tools
25+
run: |
26+
python -m pip install --upgrade pip build
27+
28+
- name: Build wheel and sdist
29+
run: |
30+
cd inference_lib
31+
python -m build
32+
33+
- name: Publish to PyPI
34+
uses: pypa/gh-action-pypi-publish@release/v1
35+
with:
36+
packages-dir: inference_lib/dist/

0 commit comments

Comments
 (0)