-
Notifications
You must be signed in to change notification settings - Fork 44
53 lines (51 loc) · 1.42 KB
/
storybook.yml
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
name: Publish Storybook
on:
push:
branches:
- main
paths:
- 'packages/fds-components-web/**'
- 'packages/fds-theme-web/**'
- '.storybook/**'
- '!packages/fds-components-web/**/package.json'
- '!packages/fds-theme-web/package.json'
- 'package.json'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: write # for checkout and commit
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: main
fetch-depth: 0
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 18
- name: Install Dependencies
run: npm ci --loglevel=error
env:
SKIP_POST_INSTALL: true
- name: Build fds-tokens
run: npm run build:tokens
- name: Build tippy theme
run: npm run build:theme-tippy
- name: Build Storybook
run: npm run build:storybook
- name: Publish to Chromatic and auto accept changes
uses: chromaui/action@v1
with:
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
autoAcceptChanges: true
buildScriptName: build:storybook
- name: Deploy Storybook 🚀
uses: JamesIves/github-pages-deploy-action@v4
with:
branch: storybook
folder: storybook-static