fix: heights #434
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Deploy Storybook | |
| on: | |
| push: | |
| branches: | |
| - "main" | |
| jobs: | |
| build-and-deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Cache node modules | |
| id: cache-npm | |
| uses: actions/cache@v3 | |
| env: | |
| cache-name: cache-node-modules | |
| with: | |
| # npm cache files are stored in `~/.npm` on Linux/macOS | |
| path: ~/.pnpm | |
| key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/pnpm-lock.yaml') }} | |
| restore-keys: | | |
| ${{ runner.os }}-build-${{ env.cache-name }}- | |
| ${{ runner.os }}-build- | |
| ${{ runner.os }}- | |
| - if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} | |
| name: List the state of node modules | |
| continue-on-error: true | |
| run: pnpm list | |
| - name: Install and Build 🔧 | |
| run: | # Install npm packages and build the Storybook files | |
| npm i -g pnpm && pnpm i | |
| pnpm run build-storybook | |
| env: | |
| FONTAWESOME_NPM_AUTH_TOKEN: ${{ secrets.FONTAWESOME_NPM_AUTH_TOKEN }} | |
| - name: Deploy 🚀 | |
| uses: JamesIves/github-pages-deploy-action@3.6.2 | |
| with: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| BRANCH: gh-pages # The branch the action should deploy to. | |
| FOLDER: storybook-static # The folder that the build-storybook script generates files. | |
| CLEAN: true # Automatically remove deleted files from the deploy branch | |
| TARGET_FOLDER: docs # The folder that we serve our Storybook files from |