mirror of
https://github.com/veeso/termscp.git
synced 2026-07-05 15:41:50 +02:00
Add Site GitHub Actions workflow running prettier format check, astro check, tests, and build on changes under site/. Wire prettier into the site package with config, ignore, and scripts, and format existing sources.
44 lines
918 B
YAML
44 lines
918 B
YAML
name: Site
|
|
|
|
on:
|
|
pull_request:
|
|
paths:
|
|
- "site/**"
|
|
- ".github/workflows/site.yml"
|
|
push:
|
|
branches: [ main ]
|
|
paths:
|
|
- "site/**"
|
|
- ".github/workflows/site.yml"
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
defaults:
|
|
run:
|
|
working-directory: site
|
|
|
|
jobs:
|
|
build-site:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
|
|
with:
|
|
persist-credentials: false
|
|
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
|
|
with:
|
|
node-version: 24
|
|
cache: npm
|
|
cache-dependency-path: site/package-lock.json
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
- name: Format
|
|
run: npm run format:check
|
|
- name: Lint
|
|
run: npm run check
|
|
- name: Test
|
|
run: npm test --if-present
|
|
- name: Build
|
|
run: npm run build
|