From 720de91ffbe03f288d88f5cfc0239cd12e859625 Mon Sep 17 00:00:00 2001 From: catrone3 Date: Tue, 14 Nov 2023 16:31:11 -0500 Subject: [PATCH] ci(workflow): release workflow update --- .github/workflows/main.yml | 3 +-- .github/workflows/release.yml | 34 ++++++++++++++++++++++++++++++++-- 2 files changed, 33 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 5bc9aa4..7a8b80c 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,5 +1,4 @@ -name: Convert Macros - +name: Linter on: pull_request: branches: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3ba6253..8b03ca4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,12 +10,42 @@ jobs: steps: - uses: actions/checkout@v2 + - name: Update settings.json url + uses: jossef/action-set-json-field@v2.1 + with: + file: module.json + field: url + value: https://github.com/${{github.repository}} + - name: Update settings.json bugs + uses: jossef/action-set-json-field@v2.1 + with: + file: module.json + field: bugs + value: https://github.com/${{github.repository}}/issues + - name: Update settings.json manifest + uses: jossef/action-set-json-field@v2.1 + with: + file: module.json + field: manifest + value: https://github.com/${{github.repository}}/releases/latest/download/module.json + - name: Update settings.json version + uses: jossef/action-set-json-field@v2.1 + with: + file: module.json + field: version + value: ${{github.event.release.tag_name}} + - name: Update settings.json download + uses: jossef/action-set-json-field@v2.1 + with: + file: module.json + field: download + value: https://github.com/${{github.repository}}/releases/download/${{github.event.release.tag_name}}/module.zip + # Create zip file - run: zip -r ./module.zip module.json LICENSE packs/ README.md # Create a release for this specific version. - name: Update Release with Files - if: !github.event.release.prerelease id: create_version_release uses: ncipollo/release-action@v1 with: @@ -23,7 +53,7 @@ jobs: name: ${{ github.event.release.name }} draft: false prerelease: false - token: ${{ secrets.GITHUB_TOKEN }} + token: ${{ secrets.GH_TOKEN }} artifacts: "./module.json, ./module.zip" tag: ${{ github.event.release.tag_name }} body: ${{ github.event.release.body }}