diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index bc4579a0ba..c0c4e91403 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -537,8 +537,6 @@ jobs: environment: release-signing env: CARGO_INCREMENTAL: "0" - RUSTC_WRAPPER: sccache - SCCACHE_GHA_ENABLED: ${{ secrets.SCCACHE_S3_BUCKET == '' && 'true' || 'false' }} RUSTFLAGS: -C debuginfo=line-tables-only -C target-feature=+crt-static VSIGN_CERT_HASH: ${{ vars.VSIGN_CERT_HASH }} VSIGN_OPERATOR_SHA1: ${{ vars.VSIGN_OPERATOR_SHA1 }} @@ -564,35 +562,6 @@ jobs: toolchain: nightly-2026-07-22 components: rust-src - # sccache must be set up before the WebView2 loader/runtime scripts: they - # run `cargo fetch` under the job-wide RUSTC_WRAPPER=sccache, so installing - # sccache only after them made cargo abort with "program not found". - - name: Setup sccache - uses: mozilla-actions/sccache-action@9e7fa8a12102821edf02ca5dbea1acd0f89a2696 # v0.0.10 - with: - version: "v0.10.0" - - - name: Configure S3 sccache - if: env.SCCACHE_GHA_ENABLED != 'true' - shell: bash - env: - CACHE_BUCKET: ${{ secrets.SCCACHE_S3_BUCKET }} - CACHE_ENDPOINT: ${{ secrets.SCCACHE_S3_ENDPOINT }} - CACHE_REGION: ${{ secrets.SCCACHE_S3_REGION }} - CACHE_KEY_PREFIX: ${{ secrets.SCCACHE_S3_KEY_PREFIX }} - CACHE_ACCESS_KEY_ID: ${{ secrets.SCCACHE_S3_ACCESS_KEY_ID }} - CACHE_SECRET_ACCESS_KEY: ${{ secrets.SCCACHE_S3_SECRET_ACCESS_KEY }} - run: | - { - echo "SCCACHE_BUCKET=${CACHE_BUCKET}" - echo "SCCACHE_ENDPOINT=${CACHE_ENDPOINT}" - echo "SCCACHE_REGION=${CACHE_REGION}" - echo "SCCACHE_S3_KEY_PREFIX=${CACHE_KEY_PREFIX}" - echo "SCCACHE_S3_USE_SSL=true" - echo "AWS_ACCESS_KEY_ID=${CACHE_ACCESS_KEY_ID}" - echo "AWS_SECRET_ACCESS_KEY=${CACHE_SECRET_ACCESS_KEY}" - } >> "$GITHUB_ENV" - - name: Prepare Win7-compatible WebView2 loader shell: pwsh run: ./.github/scripts/prepare-webview2-win7-loader.ps1 @@ -670,12 +639,6 @@ jobs: Copy-Item $installer.FullName $offlineName -Force gh release upload "${env:GITHUB_REF_NAME}" $offlineName --repo "${env:GITHUB_REPOSITORY}" --clobber - - name: Show sccache stats - if: always() - continue-on-error: true - shell: bash - run: ${SCCACHE_PATH} --show-stats - - name: Remove temporary VSign files if: always() shell: pwsh diff --git a/scripts/release.test.mjs b/scripts/release.test.mjs index 9b4a351c77..ea9127a6a6 100644 --- a/scripts/release.test.mjs +++ b/scripts/release.test.mjs @@ -7,6 +7,7 @@ import test from "node:test"; const repoRoot = new URL("..", import.meta.url).pathname; const releaseScript = join(repoRoot, "scripts/release.mjs"); +const releaseWorkflow = join(repoRoot, ".github/workflows/release.yml"); const packagesWorkflow = join(repoRoot, ".github/workflows/mcp-release.yml"); const vsignConfigPath = join(repoRoot, "src-tauri/tauri.vsign.conf.json"); @@ -123,3 +124,14 @@ test("Tauri VSign script resolves from the src-tauri working directory", () => { assert.equal(typeof scriptPath, "string"); assert.equal(existsSync(resolve(repoRoot, "src-tauri", scriptPath)), true); }); + +test("Windows 7 release build does not use sccache", () => { + const workflow = readFileSync(releaseWorkflow, "utf8"); + const start = workflow.indexOf(" build-windows-7-offline:"); + const end = workflow.indexOf("\n static-browser:", start); + + assert.notEqual(start, -1); + assert.notEqual(end, -1); + const win7Job = workflow.slice(start, end); + assert.doesNotMatch(win7Job, /RUSTC_WRAPPER|SCCACHE_|sccache/i); +});