Skip to content

Commit

Permalink
Migrate to common release action (#33)
Browse files Browse the repository at this point in the history
  • Loading branch information
s-vitaliy authored Jun 16, 2022
1 parent a2da2f0 commit a4dccb5
Showing 1 changed file with 4 additions and 20 deletions.
24 changes: 4 additions & 20 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,26 +56,10 @@ jobs:
- uses: actions/checkout@v2
- run: git fetch --prune --unshallow
- name: Create Release
env:
MAJOR_V: "0"
MINOR_V: "4"
GITHUB_TOKEN: ${{ github.token }}
run: |
set -e
providedMajor=$MAJOR_V
providedMinor=$MINOR_V
currentVersion=$(git describe --tags --abbrev=7)
currentMinor=$(echo $currentVersion | cut -d. -f2)
currentMajor=$(echo $currentVersion | cut -d. -f1 | cut -dv -f2)
if [[ $currentMajor -eq $providedMajor ]] && [[ $providedMinor -eq $currentMinor ]];
then
currentRevision=$(echo $(echo $currentVersion | rev | cut -d. -f1) | rev | cut -d- -f1)
nextRevision=$(( currentRevision + 1 ))
else
nextRevision='0'
fi
nextVersion="v$providedMajor.$providedMinor.$nextRevision"
gh release create $nextVersion --generate-notes
uses: SneaksAndData/github-actions/[email protected]
with:
major_v: 0
minor_v: 4

release_to_pypi_test:
name: Release distribution to test.pypi.org
Expand Down

0 comments on commit a4dccb5

Please sign in to comment.