2023-08-16 08:38:45 +03:00
|
|
|
name: Publish Storybook
|
|
|
|
|
2023-08-29 13:07:05 +03:00
|
|
|
env:
|
|
|
|
NODE_OPTIONS: --max-old-space-size=4096
|
|
|
|
|
2023-08-16 08:36:24 +03:00
|
|
|
on:
|
2023-08-30 19:09:04 +03:00
|
|
|
workflow_dispatch:
|
2023-08-16 08:37:53 +03:00
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
2023-08-30 19:09:04 +03:00
|
|
|
pull_request:
|
2023-08-16 08:36:24 +03:00
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
paths-ignore:
|
|
|
|
- README.md
|
|
|
|
- .github/**
|
2023-10-18 18:30:08 +03:00
|
|
|
- packages/backend/server
|
|
|
|
- packages/frontend/electron
|
2023-08-16 08:36:24 +03:00
|
|
|
- '!.github/workflows/publish-storybook.yml'
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
publish-storybook:
|
|
|
|
name: Publish Storybook
|
|
|
|
runs-on: ubuntu-latest
|
2023-08-16 19:31:13 +03:00
|
|
|
environment: development
|
2023-08-16 08:36:24 +03:00
|
|
|
steps:
|
2023-09-29 06:02:26 +03:00
|
|
|
- uses: actions/checkout@v4
|
2023-08-16 08:36:24 +03:00
|
|
|
with:
|
2023-08-16 08:54:57 +03:00
|
|
|
ref: ${{ github.event.pull_request.merge_commit_sha }}
|
2023-08-16 08:36:24 +03:00
|
|
|
# This is required to fetch all commits for chromatic
|
|
|
|
fetch-depth: 0
|
|
|
|
- name: Setup Node.js
|
|
|
|
uses: ./.github/actions/setup-node
|
|
|
|
with:
|
|
|
|
electron-install: false
|
2023-08-16 11:01:14 +03:00
|
|
|
- name: Build Plugins
|
|
|
|
run: yarn run build:plugins
|
2023-08-30 18:55:28 +03:00
|
|
|
- uses: chromaui/action-next@v1
|
2023-08-16 08:36:24 +03:00
|
|
|
with:
|
2023-10-18 18:30:08 +03:00
|
|
|
workingDir: tests/storybook
|
2023-08-30 19:09:04 +03:00
|
|
|
buildScriptName: build
|
2023-08-30 18:55:28 +03:00
|
|
|
exitOnceUploaded: true
|
|
|
|
onlyChanged: false
|
|
|
|
diagnostics: true
|
2023-08-29 13:07:05 +03:00
|
|
|
env:
|
2023-08-30 18:55:28 +03:00
|
|
|
CHROMATIC_PROJECT_TOKEN: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
|
2023-08-29 13:07:05 +03:00
|
|
|
NODE_OPTIONS: ${{ env.NODE_OPTIONS }}
|
2023-08-30 18:55:28 +03:00
|
|
|
- uses: actions/upload-artifact@v2
|
|
|
|
if: always()
|
|
|
|
with:
|
|
|
|
name: chromatic-build-artifacts-${{ github.run_id }}
|
|
|
|
path: |
|
|
|
|
chromatic-diagnostics.json
|
|
|
|
**/build-storybook.log
|