add prettier check

This commit is contained in:
silas-x 2023-01-26 09:57:27 +00:00
parent 92a14d504b
commit 34720de587
3 changed files with 7 additions and 6 deletions

View File

@ -1,7 +1,7 @@
name: Code Review
on:
pull_request:
pull_request:
branches: ['main']
push:
@ -17,8 +17,8 @@ jobs:
- run: semgrep ci --exclude 'public/charting_library'
env:
SEMGREP_RULES: p/typescript
SEMGREP_RULES: p/typescript
sca:
name: Dependency Scan
runs-on: ubuntu-latest
@ -34,7 +34,7 @@ jobs:
ignore-unfixed: true
hide-progress: true
format: 'table'
# Fail the job on critical vulnerabiliies with fix available
- name: Fail on critical vulnerabilities
uses: aquasecurity/trivy-action@master
@ -45,4 +45,4 @@ jobs:
security-checks: 'vuln' # disable secrets scanning until public
format: 'table'
severity: 'CRITICAL'
exit-code: '1'
exit-code: '1'

View File

@ -1,4 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"
yarn typecheck && yarn lint --quiet
yarn format && yarn typecheck && yarn lint --quiet

View File

@ -8,6 +8,7 @@
"dev": "rm -rf .next && next dev",
"build": "next build",
"start": "next start",
"format": "prettier --check .",
"lint": "next lint",
"typecheck": "tsc",
"prepare": "husky install",