From ce3383ca984f0164bcc240efa35184b0854edf54 Mon Sep 17 00:00:00 2001 From: Waldemar Reusch Date: Thu, 16 Mar 2023 13:42:00 +0100 Subject: [PATCH] feat(storybook): deploy storybook to github pages --- .github/workflows/ci.yaml | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 158ff67..bd514d0 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -34,20 +34,20 @@ jobs: name: build path: build - build_storybook: - runs-on: windows-latest - if: github.event.head_commit.author.name != 'actions' + deploy_storybook: + runs-on: ubuntu-latest + needs: test steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2.1.3 - with: - node-version: '16' - - uses: bahmutov/npm-install@v1 - - run: yarn build-storybook - - uses: actions/upload-artifact@v2 - with: - name: storybook - path: storybook-static + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2.1.3 + with: + node-version: '16' + - uses: bahmutov/npm-install@v1 + - run: yarn build-storybook -o ./build_storybook + - run: git remote set-url origin https://git:${GITHUB_TOKEN}@github.com/${{github.repository}}.git + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - run: npx -y -p gh-pages@3.1.0 gh-pages -d ./build_storybook --dest storybook --add -u "github-actions-bot " check_if_version_upgraded: name: Check if version upgrade