Skip to content

Appointments

Appointments #22

Workflow file for this run

name: Linting
on: pull_request
jobs:
prettier:
name: prettier
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "lts/hydrogen"
- run: npm ci
- run: npm run lint:prettier:check
eslint:
name: es-lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "lts/hydrogen"
- run: npm ci
- run: npm run lint:eslint:check
commitlint:
name: commit-lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v4
with:
node-version: "lts/hydrogen"
- run: npm ci
- run: npx commitlint --from ${{ github.event.pull_request.base.sha }} --to ${{ github.event.pull_request.head.sha }} --verbose
secretlint:
permissions:
contents: read
name: secret-lint
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
with:
# fetch history to get all changed files on push or pull_request event
fetch-depth: 0
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v44
- name: setup Node ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: "lts/hydrogen"
- name: Show changed files
run: echo "${{ steps.changed-files.outputs.all_changed_files }}"
- name: Install
if: steps.changed-files.outputs.any_changed == 'true'
run: npm ci
- name: Run secretlint
if: steps.changed-files.outputs.any_changed == 'true'
run: npx secretlint --maskSecrets ${{ steps.changed-files.outputs.all_changed_files }}