Skip to content
Open
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
56 changes: 56 additions & 0 deletions .github/workflows/cwd-api.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: CWD API CI

on:
pull_request:
paths:
- 'cwd-api/**'
- '.github/workflows/cwd-api.yml'
push:
branches:
- main
paths:
- 'cwd-api/**'
- '.github/workflows/cwd-api.yml'
workflow_dispatch:

permissions:
contents: read

concurrency:
group: cwd-api-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
verify:
runs-on: ubuntu-latest
defaults:
run:
working-directory: cwd-api
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up pnpm
uses: pnpm/action-setup@v4
with:
version: 11.9.0
run_install: false

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
cache: pnpm
cache-dependency-path: cwd-api/pnpm-lock.yaml

- name: Install dependencies
run: pnpm install --frozen-lockfile --ignore-scripts

- name: Prepare Wrangler config
run: cp wrangler.jsonc.example wrangler.jsonc

- name: Typecheck
run: pnpm typecheck

- name: Test
run: pnpm test --run
1 change: 1 addition & 0 deletions cwd-api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"dev": "wrangler dev",
"start": "wrangler dev",
"test": "vitest",
"typecheck": "tsc --noEmit",
"cf-typegen": "wrangler types"
},
"devDependencies": {
Expand Down
Loading