Skip to content

[Feat/#16] 공통 네브바 제작 #5

[Feat/#16] 공통 네브바 제작

[Feat/#16] 공통 네브바 제작 #5

Workflow file for this run

name: Chromatic Deployment
on:
pull_request:
branches:
- develop
paths:
- "**.stories.tsx"
jobs:
chromatic-deployment:
name: Chromatic
runs-on: ubuntu-latest
outputs:
statis: ${{ job.status }}
storybook_url: ${{ steps.chromatic.outputs.storybookUrl }}
currnent_time: ${{ steps.current-time.outputs.formattedTime }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup node
uses: actions/setup-node@v4
with:
node-version: 18
cache: "yarn"
- name: Set yarn version
id: set-version
run: |
yarn set version 4.1.1
echo "YARN_VERSION=$(yarn -v)" >> $GITHUB_OUTPUT
- name: Yarn cache - PnP
uses: actions/cache@v4
with:
path: |
.yarn/cache
.pnp.*
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}-${{ steps.set-version.outputs.YARN_VERSION }}
restore-keys: |
${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}-
- name: Install dependencies
run: yarn
- name: Publish to Chromatic
id: chromatic
uses: chromaui/action@latest
with:
exitZeroOnChanges: true
autoAcceptChanges: true
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
- name: Get current time
uses: josStorer/get-current-time@v2
id: current-time
with:
format: "YYYY년 MM월 DD일 HH시 mm분"
utcOffset: "+09:00"
github-storybook-comment:
runs-on: ubuntu-latest
needs: [chromatic-deployment]
steps:
- name: Comment PR
uses: thollander/actions-comment-pull-request@v3
with:
comment-tag: ${{ github.event.number }}-storybook
message: |
🧷 Storybook: ${{ needs.chromatic-deployment.outputs.storybook_url }}
⏰ Update: ${{ needs.chromatic-deployment.outputs.currnent_time }}