Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions .github/workflows/validate.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Validate

on:
pull_request:
types: [opened, synchronize, reopened]

# Concurrency configuration to cancel previous runs on new commits
concurrency:
group: validate-${{ github.event.pull_request.number }}
cancel-in-progress: true

jobs:
validate:
name: ${{ matrix.check }}
runs-on: ubuntu-latest
strategy:
matrix:
check:
- TypeScript Check
- Lint Check
- Format Check
include:
- check: TypeScript Check
command: typecheck
- check: Lint Check
command: lint
- check: Format Check
command: format:check
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'
cache-dependency-path: 'package-lock.json'
- name: Install dependencies
run: npm ci
- name: Run ${{ matrix.check }}
run: npm run ${{ matrix.command }}
7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,10 @@
"clear": "npm run prebuild -- clean && docusaurus clear",
"serve": "docusaurus serve",
"typecheck": "tsc",
"format": "prettier --write ."
"format": "prettier .",
"format:check": "npm run format -- --check",
"format:write": "npm run format -- --write",
"lint": "echo 0;"
},
"dependencies": {
"@docusaurus/core": "^3.8.1",
Expand Down Expand Up @@ -50,7 +53,7 @@
]
},
"engines": {
"node": ">=22.0"
"node": ">=22"
},
"prettier": "@harperdb/code-guidelines/prettier"
}