create release for tag with created artifact

This commit is contained in:
Gabriel Pettier 2019-11-27 01:48:37 +01:00
parent c9e2974aa2
commit 973645160e
1 changed files with 33 additions and 4 deletions

View File

@ -72,6 +72,7 @@ jobs:
PrepareManylinux:
name: prepare-manylinux
if: startsWith(github.ref, 'refs/tags/')
strategy:
matrix:
python:
@ -98,6 +99,9 @@ jobs:
Release:
name: release
needs:
- PrepareRelease
- PrepareManylinux
runs-on: 'ubuntu-latest'
steps:
- uses: actions/download-artifact@master
@ -105,8 +109,33 @@ jobs:
name: dist
path: dist
- name: create release
run: .github/actions/scripts/release.sh
# - name: create release
# run: .github/actions/scripts/release.sh
# env:
# TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }}
# GITHUB_OAUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload Test Release Asset
id: create_test_release
if: startsWith(github.ref, 'refs/tags/') && endsWith(github.ref, '-test')
uses: softprops/action-gh-release@78c309e
with:
prerelease: true
files: |
dist/*.whl
dist/*.zip
dist/*.tar.gz
env:
TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }}
GITHUB_OAUTH_TOKEN: ${{ secrets.GITHUB_OAUTH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload Release Asset
id: upload-release-asset
if: startsWith(github.ref, 'refs/tags/') && ! endsWith(github.ref, '-test')
uses: softprops/action-gh-release@78c309e
with:
files: |
dist/*.whl
dist/*.zip
dist/*.tar.gz
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}