Skip to content

Commit

Permalink
Try fix should_release
Browse files Browse the repository at this point in the history
  • Loading branch information
Carl-Hugo committed Aug 26, 2022
1 parent 4203c85 commit ebcc164
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,27 +33,29 @@ jobs:
run: |
previous="${{ steps.previoustag.outputs.tag }}"
current="v${{ steps.version.outputs.prop }}"
shouldRelease="$[$previous != $current]"
should_release="$[$previous != $current]"
echo "::set-output name=previous::$previous"
echo "::set-output name=current::$current"
echo "::set-output name=shouldRelease::$shouldRelease"
echo "::set-output name=should_release::$should_release"
echo $[$previous != $current]
- name: Output values
run: |
echo "Previous: ${{ steps.versions.outputs.previous }}"
echo "Current: ${{ steps.versions.outputs.current }}"
echo "Should release? ${{ steps.versions.outputs.shouldRelease }}"
echo "Should release? ${{ steps.versions.outputs.should_release }}"
- run: zip -r ./module.zip main.js module.json LICENSE css/ lang/
if: ${{ steps.versions.outputs.shouldRelease }}
if: ${{ steps.versions.outputs.should_release }}

- name: Update module release download url
uses: jossef/action-set-json-field@v2
with:
file: module.json
field: download
value: https://github.com/${{ github.repository }}/releases/download/${{ steps.version.outputs.prop }}/module.zip
if: ${{ steps.versions.outputs.shouldRelease }}
if: ${{ steps.versions.outputs.should_release }}

- name: Create the GitHub release
uses: softprops/action-gh-release@v1
Expand All @@ -62,4 +64,4 @@ jobs:
files: |
module.zip
module.json
if: ${{ steps.versions.outputs.shouldRelease }}
if: ${{ steps.versions.outputs.should_release }}

0 comments on commit ebcc164

Please sign in to comment.