From b408a53f8e2d46b6939d341c0e1a31aa6964a131 Mon Sep 17 00:00:00 2001 From: MeowZ#WR Date: Thu, 13 Feb 2025 14:40:19 +0800 Subject: [PATCH] Update workflows. --- .github/workflows/release.yml | 10 +++---- .github/workflows/test_release.yml | 8 ++--- .../trigger-update-dalamudplugins.yml | 29 ------------------- 3 files changed, 9 insertions(+), 38 deletions(-) delete mode 100644 .github/workflows/trigger-update-dalamudplugins.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d8f8a78b..7be817e4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -2,8 +2,8 @@ on: push: - tags-ignore: - - testing_* + tags: + - cn_* jobs: build: @@ -24,11 +24,11 @@ jobs: Expand-Archive -Force latest.zip "$env:AppData\XIVLauncher\addon\Hooks\dev" - name: Build run: | - $ver = '${{ github.ref_name }}' + $ver = '${{ github.ref_name }}' -replace 'cn_' invoke-expression 'dotnet build --no-restore --configuration Release --nologo -p:Version=$ver -p:FileVersion=$ver -p:AssemblyVersion=$ver' - name: write version into jsons run: | - $ver = '${{ github.ref_name }}' + $ver = '${{ github.ref_name }}' -replace 'cn_' $path = './Glamourer/bin/Release/Glamourer.json' $json = Get-Content -Raw $path | ConvertFrom-Json $json.AssemblyVersion = $ver @@ -64,7 +64,7 @@ jobs: - name: Write out repo.json run: | - $ver = '${{ github.ref_name }}' + $ver = '${{ github.ref_name }}' -replace 'cn_' $path = './repo.json' $json = Get-Content -Raw $path | ConvertFrom-Json $json[0].AssemblyVersion = $ver diff --git a/.github/workflows/test_release.yml b/.github/workflows/test_release.yml index 17cd66a3..85667ee9 100644 --- a/.github/workflows/test_release.yml +++ b/.github/workflows/test_release.yml @@ -3,7 +3,7 @@ name: Create Test Release on: push: tags: - - testing_* + - cn_testing_* jobs: build: @@ -24,11 +24,11 @@ jobs: Expand-Archive -Force latest.zip "$env:AppData\XIVLauncher\addon\Hooks\dev" - name: Build run: | - $ver = '${{ github.ref_name }}' -replace 'testing_' + $ver = '${{ github.ref_name }}' -replace 'cn_testing_' invoke-expression 'dotnet build --no-restore --configuration Debug --nologo -p:Version=$ver -p:FileVersion=$ver -p:AssemblyVersion=$ver' - name: write version into json run: | - $ver = '${{ github.ref_name }}' -replace 'testing_' + $ver = '${{ github.ref_name }}' -replace 'cn_testing_' $path = './Glamourer/bin/Debug/Glamourer.json' $json = Get-Content -Raw $path | ConvertFrom-Json $json.AssemblyVersion = $ver @@ -65,7 +65,7 @@ jobs: - name: Write out repo.json run: | $verT = '${{ github.ref_name }}' - $ver = $verT -replace 'testing_' + $ver = $verT -replace 'cn_testing_' $path = './repo.json' $json = Get-Content -Raw $path | ConvertFrom-Json $json[0].TestingAssemblyVersion = $ver diff --git a/.github/workflows/trigger-update-dalamudplugins.yml b/.github/workflows/trigger-update-dalamudplugins.yml deleted file mode 100644 index a3a02e63..00000000 --- a/.github/workflows/trigger-update-dalamudplugins.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: Trigger Update DalamudPlugins - -on: - workflow_dispatch: - release: - types: [published] - -concurrency: - group: ${{ github.workflow }} - cancel-in-progress: true - -jobs: - trigger: - runs-on: ubuntu-latest - steps: - - name: Trigger Workflow in Another Repository - run: | - # Set the required variables - repo_owner="MeowZWR" - repo_name="DalamudPlugin" - event_type="request-update-run-action" - - curl -L \ - -X POST \ - -H "Accept: application/vnd.github+json" \ - -H "Authorization: Bearer ${{ secrets.MEOWRSTRIGGER }}" \ - -H "X-GitHub-Api-Version: 2022-11-28" \ - https://api.github.com/repos/$repo_owner/$repo_name/dispatches \ - -d "{\"event_type\": \"$event_type\", \"client_payload\": {\"unit\": false, \"integration\": true}}"