Every push to develop (with the develop->main PR open) fired two identical CI runs: one from push, one from pull_request synchronize. Branch protection on main checks the exact commit SHA's status regardless of which event produced it, and the required check is literally named "CI / quality (push)" — so the push-triggered run alone already gates the merge. Dropping the pull_request trigger removes the duplicate without changing what's enforced. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
42 lines
1.4 KiB
YAML
42 lines
1.4 KiB
YAML
name: CI
|
|
|
|
on:
|
|
# Un seul declenchement par commit : la protection de branche sur main verifie le statut du
|
|
# commit exact en tete de la PR (par SHA, peu importe l'evenement qui l'a produit), donc le
|
|
# trigger "push" suffit deja a bloquer la fusion tant que ce commit n'est pas vert. Le trigger
|
|
# "pull_request" produirait un second run redondant pour le meme commit (contexte de statut
|
|
# different, non verifie par la regle de protection "CI / quality (push)").
|
|
push:
|
|
branches: [develop, main]
|
|
|
|
jobs:
|
|
quality:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
# node:sqlite (coachStore.ts, memory/store.ts, meetingStore.ts) exige Node >= 22.5, mais
|
|
# Vite/Rolldown ne le reconnaissent comme built-in qu'a partir de Node 24 (absent de
|
|
# module.builtinModules avant, bien que isBuiltin() le reconnaisse deja) : sous Node 22,
|
|
# la transformation plante avec "Cannot bundle Node.js built-in node:sqlite".
|
|
node-version: '24'
|
|
cache: 'npm'
|
|
|
|
- name: Install dependencies
|
|
run: npm ci --ignore-scripts
|
|
|
|
- name: TypeScript check
|
|
run: npm run typecheck
|
|
|
|
- name: ESLint
|
|
run: npm run lint
|
|
|
|
- name: Unit tests + coverage
|
|
run: npm run test:coverage
|
|
|
|
- name: Security audit
|
|
run: npm audit --audit-level=high
|