-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (46 loc) · 1.49 KB
/
ci.yml
File metadata and controls
57 lines (46 loc) · 1.49 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
name: CI
on:
push:
branches: ["main"]
pull_request:
types: [opened, synchronize]
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Check out Git repository
uses: actions/checkout@v6
with:
submodules: true
- name: Enable Corepack
run: corepack enable
- name: Set up Node.js environment
uses: actions/setup-node@v6
with:
node-version-file: .nvmrc
cache: pnpm
# Otherwise, error: ERROR: failed to build: Cache export is not supported
# for the docker driver. Switch to a different driver, or turn on the
# containerd image store, and try again. Learn more at
# https://docs.docker.com/go/build-cache-backends/
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v4
- name: Build and run Dev Container task
uses: devcontainers/ci@v0.3
with:
# Otherwise, "No runCmd set - skipping starting/running container".
# Hence, using `true` no-op
# (https://www.gnu.org/software/coreutils/manual/html_node/true-invocation.html)
runCmd: true
push: never
cacheFrom: type=gha
cacheTo: type=gha,mode=max
- name: Install dependencies
run: pnpm install
- name: Check code formatting with Prettier
run: pnpm run format:check
- name: Lint code with ESLint
run: pnpm run lint
- name: Run tests
run: pnpm run test