Skip to content
This repository was archived by the owner on Mar 24, 2025. It is now read-only.

Commit 609ff69

Browse files
authored
Merge pull request #1 from microsoft/dciborow-patch-1
Create publish_workflow.yml
2 parents 683fb22 + d9caa79 commit 609ff69

1 file changed

Lines changed: 38 additions & 0 deletions

File tree

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Python
2+
on:
3+
workflow_call:
4+
secrets:
5+
PYPI_PASSWORD:
6+
required: false
7+
TEST_PYPI_PASSWORD:
8+
required: false
9+
10+
jobs:
11+
publish:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v2
15+
16+
- name: Publish Snapshot to TestPyPi
17+
uses: dciborow/pyaction@0.0.30
18+
if: ${{ github.event_name == 'pull_request' }}
19+
with:
20+
pypi_publish: true
21+
pypi_password: ${{ secrets.TEST_PYPI_PASSWORD }}
22+
pypi_repo: testpypi
23+
version_suffix: -post${{ github.run_number }}-dev${{ github.run_attempt }}
24+
25+
- name: Publish RC to PyPi
26+
uses: dciborow/pyaction@0.0.30
27+
if: ${{ github.event_name == 'push' }}
28+
with:
29+
pypi_publish: true
30+
pypi_password: ${{ secrets.PYPI_PASSWORD }}
31+
version_suffix: -rc${{ github.run_number }}-post${{ github.run_attempt }}
32+
33+
- name: Publish Release to PyPi
34+
uses: dciborow/pyaction@0.0.30
35+
if: ${{ github.event_name == 'release' }}
36+
with:
37+
pypi_publish: true
38+
pypi_password: ${{ secrets.PYPI_PASSWORD }}

0 commit comments

Comments
 (0)