Build frontend for CodeQL; remove release analyze job

In the CodeQL workflow, add Node.js setup and a frontend build step for the Go matrix so vite emits web/dist before CodeQL's Go autobuild (the Go binary uses //go:embed all:dist and web/dist is .gitignored). In the release workflow, remove the separate Go analyze job (gofmt, go vet, staticcheck, tests) and drop its dependency from build jobs to simplify the release pipeline.
This commit is contained in:
MHSanaei
2026-05-09 17:56:16 +02:00
parent bc00d37ad8
commit 439f4cf1e8
2 changed files with 20 additions and 41 deletions
+18
View File
@@ -35,6 +35,24 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v6
# The Go binary embeds web/dist/ via //go:embed all:dist (web/web.go).
# web/dist/ is .gitignored, so CodeQL's autobuild for Go will fail with
# "pattern all:dist: no matching files found" unless vite emits it first.
- name: Setup Node.js
if: matrix.language == 'go'
uses: actions/setup-node@v6
with:
node-version: '22'
cache: 'npm'
cache-dependency-path: frontend/package-lock.json
- name: Build frontend bundle
if: matrix.language == 'go'
run: |
npm ci
npm run build
working-directory: frontend
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with: