0
0
mirror of https://github.com/PostHog/posthog.git synced 2024-12-01 04:12:23 +01:00

ci(frontend): Delete storybook-chromatic-baselines-to-master.yml (#13936)

This commit is contained in:
Michael Matloka 2023-01-26 16:03:58 +01:00 committed by GitHub
parent d4f9790234
commit 57f06ae479
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,52 +0,0 @@
name: 'Storybook Chromatic - Add baselines on push to master'
on:
push:
branches:
- master
jobs:
storybook-chromatic-accept-baselines-to-master:
runs-on: ubuntu-latest
if: github.event.pull_request.head.repo.full_name == github.repository # Don't run on forks
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0 # 👈 Required to retrieve git history (https://www.chromatic.com/docs/github-actions)
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 7.x.x
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 18
cache: pnpm
# there's no need to run chromatic on every commit,
# so we only run it if the frontend has changed
- uses: dorny/paths-filter@v2
id: changes
with:
filters: |
frontend:
- 'frontend/**'
- '.storybook/**'
- name: Install dependencies and chromatic
if: steps.changes.outputs.frontend == 'true'
run: pnpm add --save-dev chromatic
- name: Publish to Chromatic and auto accept changes to add baseline to master
# chromatic can't detect accepted baseline because we do squash merges
# so whenever we merge frontend changes to master, we need to accept a new baseline
# see https://www.chromatic.com/docs/github-actions#github-squashrebase-merge-and-the-main-branch
if: steps.changes.outputs.frontend == 'true'
uses: chromaui/action@v1
# Required options for the Chromatic GitHub Action
with:
# 👇 Chromatic projectToken, refer to the manage page to obtain it.
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
autoAcceptChanges: true # 👈 Option to accept all changes