-
Notifications
You must be signed in to change notification settings - Fork 5
72 lines (56 loc) · 1.64 KB
/
ci-check.yaml
File metadata and controls
72 lines (56 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
66
67
68
69
70
71
72
name: ci-run
on:
pull_request:
push:
branches: [main]
concurrency:
group: check-${{ github.ref }}
cancel-in-progress: true
jobs:
general-checks:
name: general-checks 🧹
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
- name: Setup Bun
uses: oven-sh/setup-bun@735343b667d3e6f658f44d0eca948eb6282f2b76 # v2.0.2
with:
bun-version: '1.3.11'
- name: Install deps
run: bun install
- name: Typecheck
run: bun run typecheck
- name: Lint
run: bun run lint
- name: Format check
run: bun run format:check
- name: Build (check)
run: bun run build
license-check:
name: license-check 📜
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
- name: Setup Node.js
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
with:
node-version: '20'
- name: Install license-checker
run: npm install -g license-checker
- name: Run license checker
run: |
license-checker --production \
--onlyAllow "MIT;Apache-2.0" \
--summary
# Special job that allows some of the jobs to be skipped or failed
# requiring others to be successful
pr-checks:
runs-on: ubuntu-latest
if: always()
needs:
- general-checks
steps:
- name: Decide on PR checks
uses: re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe # v1.2.2
with:
jobs: ${{ toJSON(needs) }}