-
Notifications
You must be signed in to change notification settings - Fork 0
35 lines (33 loc) · 986 Bytes
/
deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
name: Deploy to PyPI
on:
push:
tags-ignore: ['*.docs*']
# only run on tags, and only if they don't end with docs
jobs:
pypi-publish:
name: Publish to TestPyPI and PyPI
runs-on: ubuntu-latest
permissions:
id-token: write
steps:
- name: Download build artifacts
uses: dawidd6/action-download-artifact@v3
with:
workflow: build.yml
workflow_conclusion: success
check_artifacts: true
branch: 'master'
- name: Prepare for upload
run: |
mkdir dist
mv sdist/* dist
mv wheels/* dist
# - name: Upload to TestPyPI
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# repository-url: https://test.pypi.org/legacy/
# password: ${{ secrets.TESTPYPI_API_TOKEN }}
- name: Upload to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
# with:
# password: ${{ secrets.PYPI_API_TOKEN }}