From 6ddc42b4f15737e75e92c3beb9aca24b174f760f Mon Sep 17 00:00:00 2001 From: xyToki <7547189+xytoki@users.noreply.github.com> Date: Fri, 24 Jan 2025 14:28:47 +0800 Subject: [PATCH 1/5] feat: build diff --- .github/workflows/publish.yml | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index f5ff27c..7f57d73 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -141,10 +141,26 @@ jobs: repository: "YuehaiTeam/kachina-installer" latest: true fileName: "kachina-builder.exe" + - name: 📥 Download last release + uses: robinraju/release-downloader@v1.8 + with: + repository: "babalae/better-genshin-impact" + latest: true + fileName: "BetterGI_v*.7z" + out-file-path: 'last' + - name: Unpack Last release + run: | + cd last + 7z x "BetterGI*.7z" -otemp + if (Test-Path -Path ".\temp\BetterGI" -PathType Container) { + Rename-Item -Path ".\temp\BetterGI" -NewName ".\BetterGI" + } else { + Rename-Item -Path ".\temp" -NewName ".\BetterGI" + } - name: 📦 Pack kachina-builder run: | cd dist - ..\kachina-builder.exe gen -i BetterGI -m metadata.json -o hashed -r babalae/bettergi -t ${{ needs.build_dist.outputs.version }} --diff-ignore *[.txt,.onnx] + ..\kachina-builder.exe gen -i BetterGI -m metadata.json -o hashed -r babalae/bettergi -t ${{ needs.build_dist.outputs.version }} --diff-vers ..\last\BetterGI --diff-ignore *[.txt,.onnx] ..\kachina-builder.exe pack -c ../kachina.config.json -m metadata.json -d hashed -o BetterGI.Install.${{ needs.build_dist.outputs.version }}.exe - name: 📦 Generate archive run: | @@ -173,12 +189,6 @@ jobs: cd dist 7z x "BetterGI_v${{ needs.build_dist.outputs.version }}.7z" - name: 📥 Download MicaSetup - # run: | - # $response = Invoke-RestMethod -Uri "https://api.github.com/repos/lemutec/MicaSetup/releases/latest" - # $downloadUrl = $response.assets | Where-Object { $_.name -like "MicaSetup_v*.7z" } | Select-Object -ExpandProperty browser_download_url - # $zipFilePath = "MicaSetup.7z" - # Invoke-WebRequest -Uri $downloadUrl -OutFile $zipFilePath - # 7z x $zipFilePath uses: robinraju/release-downloader@v1.8 with: repository: "lemutec/MicaSetup" From 8d8d2a599b6c688546aab69e7f6704efc321a395 Mon Sep 17 00:00:00 2001 From: xyToki <7547189+xytoki@users.noreply.github.com> Date: Fri, 24 Jan 2025 14:40:48 +0800 Subject: [PATCH 2/5] Update publish.yml --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 7f57d73..a91d4a8 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -153,7 +153,7 @@ jobs: cd last 7z x "BetterGI*.7z" -otemp if (Test-Path -Path ".\temp\BetterGI" -PathType Container) { - Rename-Item -Path ".\temp\BetterGI" -NewName ".\BetterGI" + Move-Item -Path ".\temp\BetterGI" -NewName ".\BetterGI" } else { Rename-Item -Path ".\temp" -NewName ".\BetterGI" } From f4bb4b51d0792eb045257a36f20d3429a9c132a4 Mon Sep 17 00:00:00 2001 From: xyToki <7547189+xytoki@users.noreply.github.com> Date: Fri, 24 Jan 2025 14:52:10 +0800 Subject: [PATCH 3/5] Update publish.yml --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index a91d4a8..26b8e93 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -153,7 +153,7 @@ jobs: cd last 7z x "BetterGI*.7z" -otemp if (Test-Path -Path ".\temp\BetterGI" -PathType Container) { - Move-Item -Path ".\temp\BetterGI" -NewName ".\BetterGI" + Move-Item -Path ".\temp\BetterGI" -Destination ".\BetterGI" } else { Rename-Item -Path ".\temp" -NewName ".\BetterGI" } From 5e36ed671225c0622331d761479c325b150cbc51 Mon Sep 17 00:00:00 2001 From: xyToki <7547189+xytoki@users.noreply.github.com> Date: Sat, 25 Jan 2025 20:25:27 +0800 Subject: [PATCH 4/5] Update publish.yml --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 26b8e93..60fcd85 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -160,7 +160,7 @@ jobs: - name: 📦 Pack kachina-builder run: | cd dist - ..\kachina-builder.exe gen -i BetterGI -m metadata.json -o hashed -r babalae/bettergi -t ${{ needs.build_dist.outputs.version }} --diff-vers ..\last\BetterGI --diff-ignore *[.txt,.onnx] + ..\kachina-builder.exe gen -i BetterGI -m metadata.json -o hashed -r babalae/bettergi -t ${{ needs.build_dist.outputs.version }} --diff-vers ..\last\BetterGI --diff-ignore *[.txt,.onnx] -u .\BetterGI\BetterGI.update.exe ..\kachina-builder.exe pack -c ../kachina.config.json -m metadata.json -d hashed -o BetterGI.Install.${{ needs.build_dist.outputs.version }}.exe - name: 📦 Generate archive run: | From 39fd8192e3d5956e9f4fc0fd37fb5a9a91cb6a19 Mon Sep 17 00:00:00 2001 From: xyToki <7547189+xytoki@users.noreply.github.com> Date: Sat, 25 Jan 2025 21:01:10 +0800 Subject: [PATCH 5/5] Update publish.yml --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 60fcd85..4a28503 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -160,7 +160,7 @@ jobs: - name: 📦 Pack kachina-builder run: | cd dist - ..\kachina-builder.exe gen -i BetterGI -m metadata.json -o hashed -r babalae/bettergi -t ${{ needs.build_dist.outputs.version }} --diff-vers ..\last\BetterGI --diff-ignore *[.txt,.onnx] -u .\BetterGI\BetterGI.update.exe + ..\kachina-builder.exe gen -j 6 -i BetterGI -m metadata.json -o hashed -r babalae/bettergi -t ${{ needs.build_dist.outputs.version }} --diff-vers ..\last\BetterGI --diff-ignore *[.txt,.onnx] -u .\BetterGI\BetterGI.update.exe ..\kachina-builder.exe pack -c ../kachina.config.json -m metadata.json -d hashed -o BetterGI.Install.${{ needs.build_dist.outputs.version }}.exe - name: 📦 Generate archive run: |