From 86e34847a20a1f0272bcc336c454be53fb32ef3e Mon Sep 17 00:00:00 2001 From: Kristof Kovacs <49001742+kristofbolyai@users.noreply.github.com> Date: Thu, 8 Aug 2024 15:51:34 +0200 Subject: [PATCH] fix: Fix release Github Actions not working (and being half done) (#3) --- .../{pre-release.yml => release.yml} | 39 ++++++++++++++----- .gitignore | 2 + 2 files changed, 31 insertions(+), 10 deletions(-) rename .github/workflows/{pre-release.yml => release.yml} (54%) diff --git a/.github/workflows/pre-release.yml b/.github/workflows/release.yml similarity index 54% rename from .github/workflows/pre-release.yml rename to .github/workflows/release.yml index a98ece0..a8bc380 100644 --- a/.github/workflows/pre-release.yml +++ b/.github/workflows/release.yml @@ -1,4 +1,4 @@ -name: Publish Pre Release +name: Publish Release on: push: @@ -7,7 +7,7 @@ on: jobs: changelog: - name: Generate Changelog + name: Generate Changelog & Publish Release runs-on: ubuntu-latest outputs: tag: ${{ steps.changelog.outputs.tag }} @@ -16,33 +16,52 @@ jobs: changelog: ${{ steps.changelog.outputs.changelog }} release_id: ${{ steps.release.outputs.id }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: fetch-depth: 0 token: ${{ secrets.PRIVATE_TOKEN }} - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 16 - - run: npm install conventional-changelog-conventionalcommits + - run: | + npm install conventional-changelog-conventionalcommits@7.0.2 + npm install conventional-recommended-bump@9.0.0 - name: Create changelog id: changelog - uses: TriPSs/conventional-changelog-action@v3.17.0 + uses: TriPSs/conventional-changelog-action@v5.2.1 with: github-token: ${{ secrets.PRIVATE_TOKEN }} git-user-name: 'WynntilsBot' git-user-email: 'admin@wynntils.com' skip-version-file: true skip-git-pull: true - pre-release: true + pre-release: false + release-count: 5 + + - name: Generate the output files + run: | + chmod +x ./zip.sh + ./zip.sh + + - name: Upload output + uses: actions/upload-artifact@v4 + with: + name: output + path: | + **/output/libs/*.zip + if-no-files-found: error + overwrite: true - name: Create release if: ${{ steps.changelog.outputs.skipped != 'true' }} id: release - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@v2 with: tag_name: ${{ steps.changelog.outputs.tag }} body: ${{ steps.changelog.outputs.changelog }} - draft: true - prerelease: true + draft: false + prerelease: false + files: | + **/output/libs/*.zip \ No newline at end of file diff --git a/.gitignore b/.gitignore index dd0707b..3de24de 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,5 @@ Wynncraft 2.0 node_modules package-lock.json package.json + +.idea/ \ No newline at end of file