diff --git a/.github/workflows/build-linux.yml b/.github/workflows/build-linux.yml index 453db887..d4b97c37 100644 --- a/.github/workflows/build-linux.yml +++ b/.github/workflows/build-linux.yml @@ -40,18 +40,18 @@ jobs: id: vars shell: bash run: | - if [[ "${{ github.ref }}" == "refs/heads/master" ]]; then - echo "release=nightly" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + if [[ "${{ github.ref }}" == refs/tags/* ]]; then + echo "RELEASE=${{ github.ref_name }}" >> $GITHUB_ENV + echo "PRERELEASE=false" >> $GITHUB_ENV + elif [[ "${{ github.ref }}" == "refs/heads/master" ]]; then + echo "RELEASE=nightly" >> $GITHUB_ENV + echo "PRERELEASE=false" >> $GITHUB_ENV elif [[ "${{ github.ref }}" == "refs/heads/bleeding" ]]; then - echo "release=bleeding" >> $GITHUB_ENV - echo "prerelease=true" >> $GITHUB_ENV - elif [[ "${GITHUB_REF}" == refs/tags/* ]]; then - echo "release=${GITHUB_REF_NAME}" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + echo "RELEASE=bleeding" >> $GITHUB_ENV + echo "PRERELEASE=true" >> $GITHUB_ENV else - echo "release=nightly" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + echo "RELEASE=bleeding" >> $GITHUB_ENV + echo "PRERELEASE=true" >> $GITHUB_ENV fi - name: Install @@ -103,23 +103,11 @@ jobs: - name: List output top run: ls -lah $GITHUB_WORKSPACE - - name: Update CMD Gen Release - if: github.repository == 'openframeworks/projectGenerator' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') - uses: IsaacShelton/update-existing-release@v1.3.4 + - name: Update Release Linux + if: github.repository == 'openframeworks/apothecary' && github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') + uses: softprops/action-gh-release@v2.0.8 with: token: ${{ secrets.GITHUB_TOKEN }} - tag: ${{ env.release }} - release: ${{ env.release }} - prerelease: ${{ env.release }} - replace: false - files: projectGenerator-linux.tar.bz2 - - name: Update Project Gen GUI Release - if: github.repository == 'openframeworks/projectGenerator' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') - uses: IsaacShelton/update-existing-release@v1.3.4 - with: - token: ${{ secrets.GITHUB_TOKEN }} - tag: ${{ env.release }} - release: ${{ env.release }} - prerelease: ${{ env.release }} - replace: false - files: projectGenerator-linux-gui.gz + tag_name: ${{ env.RELEASE }} + release: ${{ env.RELEASE }} + files: projectGenerator-linux-gui.gz projectGenerator-linux.tar.bz2 diff --git a/.github/workflows/build-macos.yml b/.github/workflows/build-macos.yml index 56ee9d71..68119de6 100644 --- a/.github/workflows/build-macos.yml +++ b/.github/workflows/build-macos.yml @@ -41,18 +41,18 @@ jobs: id: vars shell: bash run: | - if [[ "${{ github.ref }}" == "refs/heads/master" ]]; then - echo "release=nightly" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + if [[ "${{ github.ref }}" == refs/tags/* ]]; then + echo "RELEASE=${{ github.ref_name }}" >> $GITHUB_ENV + echo "PRERELEASE=false" >> $GITHUB_ENV + elif [[ "${{ github.ref }}" == "refs/heads/master" ]]; then + echo "RELEASE=nightly" >> $GITHUB_ENV + echo "PRERELEASE=false" >> $GITHUB_ENV elif [[ "${{ github.ref }}" == "refs/heads/bleeding" ]]; then - echo "release=bleeding" >> $GITHUB_ENV - echo "prerelease=true" >> $GITHUB_ENV - elif [[ "${GITHUB_REF}" == refs/tags/* ]]; then - echo "release=${GITHUB_REF_NAME}" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + echo "RELEASE=bleeding" >> $GITHUB_ENV + echo "PRERELEASE=true" >> $GITHUB_ENV else - echo "release=nightly" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + echo "RELEASE=bleeding" >> $GITHUB_ENV + echo "PRERELEASE=true" >> $GITHUB_ENV fi - name: PWD and LS run: | @@ -126,13 +126,11 @@ jobs: fi - name: Test cmdline run: ../openFrameworks/apps/projectGenerator/scripts/osx/test_cmdline.sh - - name: Update Release x86_64 - if: github.repository == 'openframeworks/projectGenerator' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') - uses: IsaacShelton/update-existing-release@v1.3.4 + - name: Update Release macOS + if: github.repository == 'openframeworks/apothecary' && github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') + uses: softprops/action-gh-release@v2.0.8 with: token: ${{ secrets.GITHUB_TOKEN }} - tag: ${{ env.release }} - release: ${{ env.release }} - prerelease: ${{ env.prerelease }} - replace: false + tag_name: ${{ env.RELEASE }} + release: ${{ env.RELEASE }} files: projectGenerator-osx.zip diff --git a/.github/workflows/build-vs.yml b/.github/workflows/build-vs.yml index a426d7d4..5ed4634b 100644 --- a/.github/workflows/build-vs.yml +++ b/.github/workflows/build-vs.yml @@ -46,18 +46,18 @@ jobs: id: vars shell: bash run: | - if [[ "${{ github.ref }}" == "refs/heads/master" ]]; then - echo "release=nightly" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + if [[ "${{ github.ref }}" == refs/tags/* ]]; then + echo "RELEASE=${{ github.ref_name }}" >> $GITHUB_ENV + echo "PRERELEASE=false" >> $GITHUB_ENV + elif [[ "${{ github.ref }}" == "refs/heads/master" ]]; then + echo "RELEASE=nightly" >> $GITHUB_ENV + echo "PRERELEASE=false" >> $GITHUB_ENV elif [[ "${{ github.ref }}" == "refs/heads/bleeding" ]]; then - echo "release=bleeding" >> $GITHUB_ENV - echo "prerelease=true" >> $GITHUB_ENV - elif [[ "${GITHUB_REF}" == refs/tags/* ]]; then - echo "release=${GITHUB_REF_NAME}" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + echo "RELEASE=bleeding" >> $GITHUB_ENV + echo "PRERELEASE=true" >> $GITHUB_ENV else - echo "release=nightly" >> $GITHUB_ENV - echo "prerelease=false" >> $GITHUB_ENV + echo "RELEASE=bleeding" >> $GITHUB_ENV + echo "PRERELEASE=true" >> $GITHUB_ENV fi - name: Install dependencies shell: bash @@ -96,23 +96,19 @@ jobs: run: ../openFrameworks/apps/projectGenerator/scripts/vs/ci_frontend_package.sh - - name: Update CMD Gen Release - if: github.repository == 'openframeworks/projectGenerator' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') - uses: IsaacShelton/update-existing-release@v1.3.4 + - name: Update Release CMD + if: github.repository == 'openframeworks/apothecary' && github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') + uses: softprops/action-gh-release@v2.0.8 with: token: ${{ secrets.GITHUB_TOKEN }} - tag: ${{ env.release }} - release: ${{ env.release }} - prerelease: ${{ env.release }} - replace: false + tag_name: ${{ env.RELEASE }} + release: ${{ env.RELEASE }} files: ../openFrameworks/apps/projectGenerator/commandLine/bin/projectGenerator-vs.zip - - name: Update Project Gen GUI Release - if: github.repository == 'openframeworks/projectGenerator' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') - uses: IsaacShelton/update-existing-release@v1.3.4 + - name: Update Release GUI + if: github.repository == 'openframeworks/apothecary' && github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding') + uses: softprops/action-gh-release@v2.0.8 with: token: ${{ secrets.GITHUB_TOKEN }} - tag: ${{ env.release }} - release: ${{ env.release }} - prerelease: ${{ env.release }} - replace: false + tag_name: ${{ env.RELEASE }} + release: ${{ env.RELEASE }} files: ../openFrameworks/apps/projectGenerator/frontend/dist/projectGenerator-vs-gui.zip