forked from enbliq/ourKairos
-
Notifications
You must be signed in to change notification settings - Fork 0
65 lines (52 loc) · 1.64 KB
/
ci.yml
File metadata and controls
65 lines (52 loc) · 1.64 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
58
59
60
61
62
63
64
65
name: CI
on:
push:
branches: ['dev']
pull_request:
types: [opened, synchronize]
jobs:
build:
name: Lint, Typecheck, Build, and Test
runs-on: ubuntu-latest
steps:
- name: ⬇️ Checkout Repo
uses: actions/checkout@v4
with:
fetch-depth: 2
- name: 🟢 Setup Node.js 20
uses: actions/setup-node@v4
with:
node-version: 20
- name: 🥡 Setup pnpm
uses: pnpm/action-setup@v3
with:
version: 10.14.0
- name: 🧩 Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- name: ♻️ Setup pnpm cache
uses: actions/cache@v4
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: ♻️ Restore Turbo cache
uses: actions/cache@v4
with:
path: .turbo/cache
key: ${{ runner.os }}-turbo-${{ github.ref_name }}-${{ hashFiles('**/pnpm-lock.yaml', 'turbo.json', '.github/workflows/ci.yml') }}
restore-keys: |
${{ runner.os }}-turbo-${{ github.ref_name }}-
${{ runner.os }}-turbo-
- name: 📦 Install Dependencies
run: pnpm install --frozen-lockfile
- name: 🔍 Lint (All Apps)
run: pnpm turbo lint
- name: 📐 Type Check (All Apps)
run: pnpm turbo typecheck
- name: 🏗️ Build (All Apps)
run: pnpm turbo build
- name: 🧪 Test (All Apps)
run: pnpm turbo test