diff --git a/.github/workflows/site-preflight.yml b/.github/workflows/site-preflight.yml index 38c11f2..8734336 100644 --- a/.github/workflows/site-preflight.yml +++ b/.github/workflows/site-preflight.yml @@ -29,28 +29,35 @@ jobs: node-version: "22" - name: Install audit tools - run: npm install --no-audit --no-fund + run: npm ci --no-audit --no-fund - name: Prepare reports directory run: mkdir -p qa-results + # BLOCKING: the bootloader loads these at runtime with no build step. - name: Check JavaScript syntax - run: | - set -e - for file in ./*.js; do - node --check "$file" - done + run: npm run qa:js + # BLOCKING: guards architecture, footer, truth and QA drift. - name: Check portfolio architecture consistency run: npm run qa:portfolio + # BLOCKING: fully determined by the repository, so it cannot flake. + - name: Validate internal links + run: npm run qa:links 2>&1 | tee qa-results/internal-links.txt + + # BLOCKING on structural errors only: html-validate exits 0 when just + # warnings remain, so intentional warnings stay visible without gating. - name: Validate HTML - continue-on-error: true - run: npm run qa:html 2>&1 | tee qa-results/html-validation.txt + run: | + set -o pipefail + npm run qa:html 2>&1 | tee qa-results/html-validation.txt + # BLOCKING: the baseline is genuinely clean (0 issues). - name: Check English and Turkish spelling - continue-on-error: true - run: npm run qa:spelling 2>&1 | tee qa-results/spelling.txt + run: | + set -o pipefail + npm run qa:spelling 2>&1 | tee qa-results/spelling.txt - name: Start local site run: | @@ -64,10 +71,12 @@ jobs: cat qa-results/local-server.log exit 1 + # BLOCKING: a real WCAG2AA failure must not be merged. - name: Audit accessibility on mobile viewport - continue-on-error: true run: npm run qa:a11y -- --json > qa-results/accessibility.json 2> qa-results/accessibility-errors.txt + # REPORT-ONLY: performance depends on runner and third-party CDN latency, + # so it must not gate merges. Scores are summarized and uploaded below. - name: Run Lighthouse CI continue-on-error: true run: npm run qa:lighthouse 2>&1 | tee qa-results/lighthouse.txt @@ -126,6 +135,8 @@ jobs: - name: Check out repository uses: actions/checkout@v5 + # REPORT-ONLY: external hosts rate-limit and block bots. Deterministic + # internal links are enforced by the blocking qa:links step above. - name: Scan HTML and Markdown links id: lychee uses: lycheeverse/lychee-action@v2 diff --git a/404.html b/404.html index 23f6c11..ba6b275 100644 --- a/404.html +++ b/404.html @@ -69,18 +69,15 @@