From 2bdb5e29af7d92079a177653fe21422f50d7310b Mon Sep 17 00:00:00 2001 From: Admin Date: Sun, 5 Apr 2026 18:01:00 +0500 Subject: [PATCH] perf: reuse UI build artifact for source map upload in CI Pass build output from check-ui to upload-sourcemaps via artifact instead of rebuilding from scratch. Saves ~4-5 min (npm ci + npm run build) from the upload-sourcemaps job. --- .gitea/workflows/release.yaml | 28 ++++++++++++---------------- 1 file changed, 12 insertions(+), 16 deletions(-) diff --git a/.gitea/workflows/release.yaml b/.gitea/workflows/release.yaml index 5a4385d..66ee8b5 100644 --- a/.gitea/workflows/release.yaml +++ b/.gitea/workflows/release.yaml @@ -55,6 +55,13 @@ jobs: - name: Build run: npm run build + - name: Upload build artifacts + uses: actions/upload-artifact@v4 + with: + name: ui-build + path: ui/build + retention-days: 1 + # ── docker: backend ─────────────────────────────────────────────────────────── docker-backend: name: Docker / backend @@ -140,29 +147,18 @@ jobs: name: Upload source maps runs-on: ubuntu-latest needs: [check-ui] - defaults: - run: - working-directory: ui steps: - - uses: actions/checkout@v4 - - - uses: actions/setup-node@v4 - with: - node-version: "22" - cache: npm - cache-dependency-path: ui/package-lock.json - - - name: Install dependencies - run: npm ci - - name: Compute release version (strip leading v) id: ver run: | V="${{ gitea.ref_name }}" echo "version=${V#v}" >> "$GITHUB_OUTPUT" - - name: Build with source maps - run: npm run build + - name: Download build artifacts + uses: actions/download-artifact@v4 + with: + name: ui-build + path: build - name: Install sentry-cli run: npm install -g @sentry/cli