Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 19 additions & 17 deletions .github/workflows/chromatic.yml
Original file line number Diff line number Diff line change
@@ -1,30 +1,32 @@
# .github/workflows/chromatic.yml

name: "Chromatic"
name: 'Chromatic Deployment'

on:
push:
paths:
- 'src/components/**/*.{js,jsx,ts,tsx}'

branches:
- main # Adjust this if your main branch has a different name
# pull_request: # No need for PRs for now
# branches:
# - main # Adjust this if your main branch has a different name

jobs:
chromatic:
chromatic-deployment:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- uses: actions/checkout@v3
with:
fetch-depth: 0 # Required for Chromatic to retrieve git history

- name: Use Node.js
uses: actions/setup-node@v3
with:
fetch-depth: 0
node-version: '18' # Adjust this to your project's Node.js version

- name: Install dependencies
# ⚠️ Pick one of these, matching the package manager for your project
run: npm ci
# run: pnpm install
# run: yarn install --immutable --immutable-cache --check-cache
run: npm ci # Use 'yarn install --frozen-lockfile' if you use Yarn

- name: Publish to Chromatic
uses: chromaui/action@latest
uses: chromaui/action@v1
with:
# ⚠️ Make sure to configure a `CHROMATIC_PROJECT_TOKEN` repository secret
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
# Optional: Add any additional Chromatic CLI flags here
# For example: --exit-zero-on-changes
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Add newline at end of file.

Add a newline character at the end of the file to comply with POSIX standards.

           # Optional: Add any additional Chromatic CLI flags here
           # For example: --exit-zero-on-changes
+
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
# For example: --exit-zero-on-changes
# For example: --exit-zero-on-changes
🧰 Tools
🪛 yamllint

[error] 32-32: no new line character at the end of file

(new-line-at-end-of-file)

Loading