Skip to content

Merge pull request #147 from sakupi01/feat/2024-lookback #1706

Merge pull request #147 from sakupi01/feat/2024-lookback

Merge pull request #147 from sakupi01/feat/2024-lookback #1706

Workflow file for this run

name: Release Storybook to GitHubPages
on: [push]
jobs:
release:
name: Storybook Build
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ vars.TURBO_TEAM }}
steps:
- name: Checkout Commit
uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Setup Bun
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
- name: Install dependencies
run: bun install
- name: Cache bun dependencies
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4
id: bun-cache
with:
path: node_modules
key: ${{ runner.os }}-bun-${{ hashFiles('**/bun.lockb') }}
restore-keys: ${{ runner.os }}-bun
- name: Build storybook of @repo/ui
run: bun run build:storybook
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./packages/ui/storybook-static
- name: post preview url to pull-request
if: github.event.action == 'opened'
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7
with:
script: |
github.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '🎉 Storybook preview created!!\n' +
'https://sakupi01.github.io/sakupi01.com/'
})