File tree Expand file tree Collapse file tree 4 files changed +37
-0
lines changed Expand file tree Collapse file tree 4 files changed +37
-0
lines changed Original file line number Diff line number Diff line change 2727 secrets :
2828 CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
2929
30+ publish-storybook-pr :
31+ name : Publish Storybook to `pr/${{ github.event.number }}` folder
32+ needs : lint-build-test
33+ if : ${{ github.event_name == 'pull_request' }}
34+ permissions :
35+ contents : write
36+ uses : ./.github/workflows/publish-github-pages.yml
37+ with :
38+ build_script : yarn workspace @metamask/snaps-sdk build && yarn workspace @metamask/snaps-storybook build && yarn workspace @metamask/snaps-sdk build:storybook
39+ publish_dir : ./packages/snaps-sdk/storybook-static
40+ destination_dir : storybook/pr/${{ github.event.number }}
41+ secrets :
42+ PUBLISH_PAGES_TOKEN : ${{ secrets.PUBLISH_PAGES_TOKEN }}
43+
3044 publish-staging-simulator :
3145 name : Publish Snaps Simulator to `staging` folder
3246 needs : lint-build-test
Original file line number Diff line number Diff line change 1+ on :
2+ workflow_call :
3+ secrets :
4+ PUBLISH_PAGES_TOKEN :
5+ required : true
6+
7+ jobs :
8+ publish-storybook-pr :
9+ name : Publish Storybook to `pr` folder
10+ needs : lint-build-test
11+ permissions :
12+ contents : write
13+ uses : ./.github/workflows/publish-github-pages.yml
14+ with :
15+ build_script : yarn workspace @metamask/snaps-simulator build
16+ publish_dir : ./packages/snaps-simulator/dist/webpack/main
17+ destination_dir : snaps-simulator/staging
18+ secrets :
19+ PUBLISH_PAGES_TOKEN : ${{ secrets.PUBLISH_PAGES_TOKEN }}
Original file line number Diff line number Diff line change @@ -78,3 +78,6 @@ packages/examples/examples/webpack/index.html
7878
7979# Ubuntu package files
8080.deb
81+
82+ # Storybook
83+ storybook-static
Original file line number Diff line number Diff line change 5252 "lint:fix" : " yarn lint:eslint --fix && yarn lint:misc --write" ,
5353 "lint:changelog" : " ../../scripts/validate-changelog.sh @metamask/snaps-sdk" ,
5454 "build" : " tsup --clean && yarn build:types" ,
55+ "build:storybook" : " storybook build" ,
5556 "build:types" : " tsc --project tsconfig.build.json" ,
5657 "clean" : " rimraf '*.tsbuildinfo' 'dist'" ,
5758 "publish:preview" : " yarn npm publish --tag preview" ,
You can’t perform that action at this time.
0 commit comments