Skip to content

Commit e0f423c

Browse files
authored
Add action for pypi publishing
1 parent 7cdd4fb commit e0f423c

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

.github/workflows/pypi.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# This workflow will upload a Python Package using Twine when a release is created
2+
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
3+
4+
name: Upload Python Package
5+
6+
on:
7+
release:
8+
types: [released, prereleased]
9+
10+
jobs:
11+
deploy:
12+
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v2
17+
- name: Set up Python
18+
uses: actions/setup-python@v2
19+
with:
20+
python-version: '3.7'
21+
- name: Install dependencies
22+
run: |
23+
python -m pip install --upgrade pip
24+
pip install setuptools wheel twine build
25+
- name: Build the servicex_cli wheel
26+
env:
27+
servicex_version: ${{ github.ref }}
28+
run: |
29+
python -m build --sdist --wheel
30+
- name: Publish servicex_cli to PyPI
31+
uses: pypa/gh-action-pypi-publish@v1.3.1
32+
with:
33+
user: __token__
34+
password: ${{ secrets.pypi_password_servicex }}
35+
repository_url: https://test.pypi.org/legacy/

0 commit comments

Comments
 (0)