Skip to content

Commit

Permalink
fix pypi-publish action
Browse files Browse the repository at this point in the history
  • Loading branch information
giancastro committed Apr 27, 2021
1 parent 05aa22c commit a4ae77f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/pypi-publish.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
name: Publish package to PyPI
on:
release:
types: [published]
push:
tags:
- '*'
jobs:
publish:
runs-on: ubuntu-18.04
Expand All @@ -12,11 +13,10 @@ jobs:
with:
python-version: 3.8
- name: Get release version
env:
TAG_VERSION: ${{ steps.vars.outputs.tag }}
run: |
echo "CHANGELOG_VERSION=$(cat CHANGELOG.md | grep -oP '(?<=###\s)(.*)(?=\s\-)' | head -n 1 | sed 's/Version\s/v/')" >> $GITHUB_ENV
echo "CONDA_VERSION=$(cat conda.recipe/meta.yaml | grep -oP '(version\:.*)' | head -n 1 | sed 's/version\:\s/v/')" >> $GITHUB_ENV
echo "TAG_VERSION=`echo $(git describe --tags --abbrev=0)`" >> $GITHUB_ENV
- name: Check changelog release version
if: ${{ env.TAG_VERSION != env.CHANGELOG_VERSION }}
run: |
Expand Down

0 comments on commit a4ae77f

Please sign in to comment.