-
Notifications
You must be signed in to change notification settings - Fork 34
92 lines (78 loc) · 2.77 KB
/
Copy pathci.yml
File metadata and controls
92 lines (78 loc) · 2.77 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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# this workflow will run on every pr to make sure the project is following the guidelines
# after labeler, run other actions with strict permissions
name: CI
on:
push:
branches: [main]
pull_request:
branches: ["**"]
merge_group:
jobs:
check:
runs-on: ubuntu-latest
name: Run checks
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/setup
- run: pnpm check
tsc:
runs-on: ubuntu-latest
name: Run typecheck
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/setup
- run: pnpm typecheck
test:
runs-on: ubuntu-latest
name: Run tests
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/setup
# publish-smoke.test.ts imports the generated publishables (gitignored).
- run: pnpm build:registry
- run: pnpm test
registry-drift:
runs-on: ubuntu-latest
name: Check generated registry artifacts are up to date
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/setup
- name: Regenerate committed registry artifacts
run: pnpm build:registry
- name: Fail if any committed generated artifact is stale
run: |
git diff --exit-code -- \
www/src/registry/__generated__/demos.tsx \
www/src/registry/__generated__/icons.tsx \
www/src/modules/create/__generated__/examples.tsx \
www/src/registry/__generated__/base-css.ts \
www/src/registry/__generated__/registry-items.ts \
www/src/registry/base/colors.css \
www/src/registry/base/theme.css \
www/src/registry/__generated__/__tabler__.ts \
www/src/registry/__generated__/__hugeicons__.ts \
www/src/registry/__generated__/__remix__.ts \
|| { echo '::error::Committed generated registry artifacts are out of date. Run `pnpm build:registry` and commit the result.'; exit 1; }
references-drift:
runs-on: ubuntu-latest
name: Check generated API references are up to date
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/setup
- name: Regenerate committed API reference files
run: pnpm build:references
- name: Fail if any committed reference file is stale
run: |
git status --porcelain -- www/src/modules/docs/references/generated/ | grep -q . \
&& { git status --porcelain -- www/src/modules/docs/references/generated/; echo '::error::Committed API reference files are out of date. Run `pnpm build:references` and commit the result.'; exit 1; } \
|| true