Skip to content

Commit 5e98c15

Browse files
committed
github workflow
1 parent 9d8c22d commit 5e98c15

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Build and Package Storybook
2+
3+
on:
4+
workflow_dispatch: # This makes it manually triggerable from GitHub UI
5+
6+
jobs:
7+
build-and-release:
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- uses: actions/checkout@v4
12+
13+
- name: Setup Node.js
14+
uses: actions/setup-node@v4
15+
with:
16+
node-version: '18'
17+
18+
- name: Install Dependencies
19+
working-directory: ./storybook
20+
run: npm install
21+
22+
- name: Build Storybook
23+
working-directory: ./storybook
24+
run: npm run build-storybook
25+
26+
- name: Create Zip Archive
27+
working-directory: ./storybook
28+
run: zip -r storybook-static.zip storybook-static/
29+
30+
- name: Create Release
31+
uses: softprops/action-gh-release@v1
32+
with:
33+
files: ./storybook/storybook-static.zip
34+
tag_name: storybook-${{ github.run_number }}
35+
name: Storybook Build ${{ github.run_number }}
36+
body: Automated Storybook build
37+
draft: false
38+
prerelease: false
39+
env:
40+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)