From af488288f2173f0edaf2129602307e39feb0eb67 Mon Sep 17 00:00:00 2001 From: "M. Mert Yildiran" Date: Fri, 30 Dec 2022 06:13:38 +0300 Subject: [PATCH] :construction_worker: Fix `release.yml` more --- .github/workflows/release.yml | 31 ++++++++----------------------- 1 file changed, 8 insertions(+), 23 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fcd0ea9e6..88ea6a58d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,7 +1,7 @@ on: push: - branches: - - master + tags: + - '*' name: Release @@ -22,28 +22,13 @@ jobs: - name: Check out the repo uses: actions/checkout@v2 - - name: Determine versioning strategy - uses: haya14busa/action-cond@v1 - id: condval - with: - cond: ${{ github.ref == 'refs/heads/main' }} - if_true: "stable" - if_false: "stable" - - - name: Auto Increment Ver Action - uses: docker://igorgov/auto-inc-ver:v2.0.0 - id: versioning - with: - mode: ${{ steps.condval.outputs.value }} - suffix: 'dev' - github_token: ${{ secrets.GITHUB_TOKEN }} - - - name: Get version parameters + - name: Version + id: version shell: bash run: | + echo ::set-output name=tag::${GITHUB_REF#refs/*/} echo "##[set-output name=build_timestamp;]$(echo $(date +%s))" echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" - id: version_parameters - name: Build run: make build-all @@ -58,9 +43,9 @@ jobs: with: token: ${{ secrets.GITHUB_TOKEN }} artifacts: "bin/*" - commit: ${{ steps.version_parameters.outputs.branch }} - tag: ${{ steps.versioning.outputs.version }} - prerelease: ${{ github.ref != 'refs/heads/main' }} + commit: ${{ steps.version.outputs.branch }} + tag: ${{ steps.version.outputs.tag }} + prerelease: ${{ github.ref != 'refs/heads/master' }} bodyFile: 'bin/README.md' brew-tap: