Simpl-Resultat/.forgejo/workflows/check-frontend.yml
le king fu 71a4e1e88f
All checks were successful
PR Check — Frontend / frontend (pull_request) Successful in 1m51s
PR Check — Rust / rust (pull_request) Successful in 4m46s
ci: move check-frontend, audit and release from Node 20 to Node 24
Node 20 reached end of life on 2026-04-30. check-frontend.yml, audit.yml
and release.yml now install Node.js 24 through NodeSource's setup_24.x,
as check-rust.yml has done since #375. Each step still prints
`node --version` in the job log.

The concurrency comment of check-rust.yml claimed the key cancels
obsolete runs on force-push. la-compagnie-maximus docs/forgejo-ops.md
measured the opposite on Forgejo 8.0.3: no pull_request run was
cancelled by a later one, and push runs are cancelled without the key.
The comment now states that measurement; the keys stay (harmless,
meaningful where honoured), and check-frontend.yml and audit.yml point
to it.

release.yml names the trust it places in NodeSource: the script runs as
root in the job container, whose Node.js then runs `npx tauri build`
with TAURI_SIGNING_PRIVATE_KEY. Kept on purpose, also documented in
docs/architecture.md, whose release.yml section described two jobs
(windows-latest, ubuntu-22.04) where there is one containerised job
cross-compiling Windows with cargo-xwin.

release.yml only runs on a tag, so Node 24 there is proven at the next
release: the /release skill now reads `node --version` from the release
run's log (step 9), and STATE.md lists it under the checks due at the
next release.

No CHANGELOG entry: CI only.

Resolves #376

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 19:40:28 -04:00

67 lines
2 KiB
YAML

name: PR Check — Frontend
# Frontend half of the former check.yml (split in #232).
#
# Filtered with paths-ignore rather than an allowlist: this job costs ~2.5 min,
# so running it when it was not strictly needed is cheap, while silently NOT
# running it is not. A root-level config file added later would drop out of an
# allowlist without anyone noticing; here it fails safe.
#
# No `branches:` filter — see check-rust.yml.
on:
pull_request:
paths-ignore:
- 'src-tauri/**'
- '.cargo/**'
- 'docs/**'
- 'reports/**'
- 'tasks/**'
- '.github/**'
- '.claude/**'
- '.forgejo/workflows/check-rust.yml'
- '.forgejo/workflows/audit.yml'
- '.forgejo/workflows/release.yml'
- '*.md'
- 'LICENSE'
# Same concurrency key as check-rust.yml, whose comment says what it does on
# Forgejo 8.0.3 (#376) and why each workflow has its own group.
concurrency:
group: ci-frontend-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
frontend:
runs-on: ubuntu
container: ubuntu:22.04
steps:
- name: Install Node.js 24
run: |
apt-get update
apt-get install -y --no-install-recommends curl ca-certificates git
curl -fsSL https://deb.nodesource.com/setup_24.x | bash -
apt-get install -y nodejs
node --version
npm --version
- name: Checkout
uses: https://github.com/actions/checkout@v4
# No npm cache step, by decision (#234). The runner's cache works since
# 2026-10-03, but it keeps what a pull_request run saves private to that
# PR, and this workflow runs on PRs only: a cache would serve later
# pushes to the same PR, while `npm ci` takes 9s here (run 456) and
# each PR's first run would pay for the save.
- name: Install dependencies
run: npm ci
- name: Build (tsc + vite)
run: npm run build
- name: Tests (vitest)
run: npm test