Skip to content

Commit 8fd2dee

Browse files
committed
Move chromatic to dedicated workflow
1 parent dfbb01f commit 8fd2dee

File tree

2 files changed

+28
-5
lines changed

2 files changed

+28
-5
lines changed

.github/workflows/chromatic.yml

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: "Chromatic"
2+
3+
on:
4+
# Runs on pushes targeting the default branch
5+
push:
6+
branches: ["main"]
7+
8+
# Allows you to run this workflow manually from the Actions tab
9+
workflow_dispatch:
10+
11+
jobs:
12+
chromatic:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v4
17+
with:
18+
fetch-depth: 0
19+
20+
- name: Install dependencies
21+
# ⚠️ Pick one of these, matching the package manager for your project
22+
run: npm ci
23+
24+
- name: Run Chromatic
25+
uses: chromaui/action@latest
26+
with:
27+
# ⚠️ Make sure to configure a `CHROMATIC_PROJECT_TOKEN` repository secret
28+
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}

.github/workflows/deploy-github-pages.yaml

-5
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,3 @@ jobs:
4242
- name: Deploy to GitHub Pages
4343
id: deployment
4444
uses: actions/deploy-pages@v2
45-
- name: Run Chromatic
46-
uses: chromaui/action@latest
47-
with:
48-
# ⚠️ Make sure to configure a `CHROMATIC_PROJECT_TOKEN` repository secret
49-
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}

0 commit comments

Comments
 (0)