1
0
mirror of synced 2026-10-23 07:08:55 +03:00
Files
pgadmin4/.github/workflows/check-javascript-style.yml
dev-hari-prasad 351376af7f Enforce --immutable on every yarn install, in CI and the release builds (#10389)
In the four GitHub Actions workflows the flag is documentation only, since
Yarn's enableImmutableInstalls already defaults to true whenever CI is set in
the environment, but making it explicit means the intent is visible in the
workflow rather than implied by the runner.

The six installs that run outside CI are where this actually changes
behaviour: the Makefile, the Dockerfile, and the pip, Linux, macOS and Windows
packaging builds all run with yarn.lock beside them, and until now any of them
would quietly rewrite the lockfile rather than fail. A release build that
rewrites the lockfile is shipping something other than what we reviewed, so
failing loudly there is the point of the exercise.
2026-09-22 16:50:39 +01:00

53 lines
1.2 KiB
YAML

name: Check Javascript style
on:
push:
branches: [ "master" ]
paths:
- 'web/**/*.js'
- 'web/**/*.jsx'
- 'web/package.json'
- 'web/yarn.lock'
- 'web/.eslintrc.js'
- 'web/.yarnrc.yml'
- '.github/workflows/check-javascript-style.yml'
pull_request:
branches: [ "master" ]
paths:
- 'web/**/*.js'
- 'web/**/*.jsx'
- 'web/package.json'
- 'web/yarn.lock'
- 'web/.eslintrc.js'
- 'web/.yarnrc.yml'
- '.github/workflows/check-javascript-style.yml'
workflow_dispatch:
concurrency:
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
cancel-in-progress: true
jobs:
check-javascript-style:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v7
# Corepack reads packageManager from web/package.json and provisions
# exactly that Yarn: a single pinned download, with nothing written
# into the checkout.
- name: Enable Corepack
run: corepack enable
- name: Install Node modules
run: |
cd web
yarn install --immutable
- name: Run the linter
run: |
cd web
yarn run linter