mirror of
https://github.com/chillpadclub/bedolaga-cabinet.git
synced 2026-07-28 17:43:47 +00:00
- Add husky with lint-staged for pre-commit checks (eslint --fix, prettier --write) - Add reusable lint.yml workflow (eslint, prettier, tsc) - Gate docker, release, and CI pipelines behind lint job via needs: lint
30 lines
528 B
YAML
30 lines
528 B
YAML
name: Lint & Format
|
|
|
|
on:
|
|
workflow_call:
|
|
|
|
jobs:
|
|
lint:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: '20'
|
|
cache: 'npm'
|
|
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
|
|
- name: Run ESLint
|
|
run: npm run lint
|
|
|
|
- name: Check formatting
|
|
run: npm run format:check
|
|
|
|
- name: Run TypeScript check
|
|
run: npx tsc --noEmit
|