Skip to content

Commit

Permalink
ci: storybook chromatic publish ci 세팅 (#21)
Browse files Browse the repository at this point in the history
- storybook chromatic publish ci 세팅
  • Loading branch information
saseungmin authored Jan 15, 2024
1 parent b8dac0c commit 81120b8
Showing 1 changed file with 36 additions and 2 deletions.
38 changes: 36 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,23 @@ on:
push:
branches: [develop]

env:
CACHED_DEPENDENCY_PATHS: |
${{ github.workspace }}/.yarn/cache
${{ github.workspace }}/.yarn/unplugged
CACHED_BUILD_PATHS: ${{ github.workspace }}/.next
BUILD_CACHE_KEY: ${{ github.sha }}
DEFAULT_NODE_VERSION: "v18.17.0"

jobs:
continuous-integration:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js 20.x
- name: Use Node.js 18.17.0
uses: actions/setup-node@v3
with:
node-version: '20'
node-version: ${{ env.DEFAULT_NODE_VERSION }}

- name: Install dependencies
run: yarn install --immutable
Expand All @@ -25,3 +33,29 @@ jobs:

- name: Check Unit Test
run: yarn test:coverage

job_publish_storybook_chromatic:
name: Chromatic Publish
runs-on: ubuntu-latest
steps:
- name: Check out current commit (${{ github.sha }})
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Set up Node
uses: actions/setup-node@v2
with:
node-version: ${{ env.DEFAULT_NODE_VERSION }}

- name: Set node linker to nodeModules
run: yarn config set nodeLinker "node-modules"

- name: Install dependencies
run: yarn install --immutable

- uses: chromaui/action@v1
with:
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
skip: "dependabot/**"
exitOnceUploaded: true
onlyChanged: true

0 comments on commit 81120b8

Please sign in to comment.