Skip to content

Commit

Permalink
Update python_publish.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
guiferviz authored May 30, 2020
1 parent 48afd19 commit e4bae36
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .github/workflows/python_publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ name: Upload Python Package to PyPi

on:
release:
types: [created]
types: [ created ]

jobs:
deploy:
Expand All @@ -22,6 +22,12 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- name: Update version
run: |
# Get version numbers form GITHUB_REF.
VERSION=$(sed -n 's/.*\/v\(.*\)/\1/p' <<< $GITHUB_REF)
# Substitute value in _version file.
sed -i "s/0.0.0/$VERSION/" recipipe/_version.py
- name: Build and publish
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
Expand Down

0 comments on commit e4bae36

Please sign in to comment.