Skip to content

Merge pull request #1 from alterviewxyz/feat/add-storybook #3

Merge pull request #1 from alterviewxyz/feat/add-storybook

Merge pull request #1 from alterviewxyz/feat/add-storybook #3

Workflow file for this run

name: Storybook
on:
push:
branches: ["main"]
pull_request:
types: [opened, synchronize]
jobs:
build:
runs-on: ubuntu-latest
steps:
# Checkout the repository
- uses: actions/checkout@v4
- name: Cache turbo build setup
uses: actions/cache@v4
with:
path: .turbo
key: ${{ runner.os }}-turbo-${{ github.sha }}
restore-keys: |
${{ runner.os }}-turbo-
# Setup pnpm
- uses: pnpm/action-setup@v3
with:
version: 8
# Install dependencies
- name: Install Dependencies
run: pnpm install
# Build Storybook
- name: Build Storybook
run: pnpm run build-storybook
# Deploy to GitHub Pages (only on push to main)
- name: Deploy to GitHub Pages
if: github.ref == 'refs/heads/main' && github.event_name == 'push'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./dist-storybook
# Optionally specify the branch
# publish_branch: gh-pages