From b2ffd557e3d8914d41e31fe390de0efb4c8a206b Mon Sep 17 00:00:00 2001 From: Cahllagerfeld <43843195+Cahllagerfeld@users.noreply.github.com> Date: Fri, 18 Aug 2023 10:24:21 +0000 Subject: [PATCH] feat: add github action --- .github/workflows/storybook.yaml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/storybook.yaml diff --git a/.github/workflows/storybook.yaml b/.github/workflows/storybook.yaml new file mode 100644 index 0000000..acd258f --- /dev/null +++ b/.github/workflows/storybook.yaml @@ -0,0 +1,31 @@ +name: Storybook +on: + push: + branches: + - main # if any push happens on branch `main`, run this workflow. You could also add `paths` to detect changes in specific folder + +jobs: + build-and-deploy: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2.3.1 + + - uses: actions/setup-node@v3 + with: + node-version: 18 + + - uses: pnpm/action-setup@v2 + with: + version: 8 + + - name: Install and Build + run: | + pnpm + pnpm build-storybook + + - name: Deploy + uses: JamesIves/github-pages-deploy-action@3.6.2 + with: + branch: gh-pages + folder: storybook-static # output folder from `npm run build-storybook`