-
Notifications
You must be signed in to change notification settings - Fork 6
88 lines (84 loc) · 2.25 KB
/
Copy pathreact-components.yaml
File metadata and controls
88 lines (84 loc) · 2.25 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
name: React components
on:
push:
jobs:
prepare:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Install node
uses: actions/setup-node@v4
with:
node-version: 24
cache: "pnpm"
- name: Install dependencies
run: pnpm install --frozen-lockfile
lint:
needs: prepare
runs-on: ubuntu-24.04
steps:
- name: Lint
working-directory: ./packages/react-components
run: pnpm --filter @health-samurai/react-components run check
typecheck:
needs: prepare
runs-on: ubuntu-24.04
steps:
- name: Type check
working-directory: ./packages/react-components
run: pnpm --filter @health-samurai/react-components run tsc:check
build:
needs: prepare
runs-on: ubuntu-24.04
steps:
- name: Build
working-directory: ./packages/react-components
run: pnpm --filter @health-samurai/react-components run build
build-storybook:
needs: prepare
runs-on: ubuntu-24.04
steps:
- name: Build storybook
working-directory: ./packages/react-components
run: pnpm --filter @health-samurai/react-components run build-storybook
publish-storybook-gate:
needs:
- lint
- typecheck
- build
- build-storybook
runs-on: ubuntu-24.04
if: success() && github.ref == 'refs/heads/master'
steps:
- run: "true"
storybook-prepare-pages:
needs: publish-storybook-gate
runs-on: ubuntu-24.04
permissions:
pages: write
id-token: write
steps:
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Upload
uses: actions/upload-pages-artifact@v3
with:
path: packages/react-components/storybook-static
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
storybook-deploy-pages:
needs: storybook-prepare-pages
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4