File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,8 @@ concurrency:
14
14
jobs :
15
15
build :
16
16
runs-on : ubuntu-latest
17
+ env :
18
+ HAVE_CHROMATIC_PROJECT_TOKEN : ${{ secrets.CHROMATIC_PROJECT_TOKEN != '' }}
17
19
strategy :
18
20
matrix :
19
21
node : [ '20' ]
@@ -131,14 +133,18 @@ jobs:
131
133
npm run build-storybook
132
134
133
135
- name : Publish to Chromatic
134
- if : ${{ github.actor != 'dependabot[bot]' }}
136
+ if : ${{ github.actor != 'dependabot[bot]' && env.HAVE_CHROMATIC_PROJECT_TOKEN == 'true' }}
135
137
uses : chromaui/action@latest
136
138
# Options required to the GitHub Chromatic Action
137
139
with :
138
140
# 👇 Chromatic projectToken, refer to the manage page to obtain it.
139
141
token : ${{ secrets.GH_TOKEN }}
140
142
projectToken : ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
141
143
storybookBuildDir : " storybook-static"
144
+ - name : Publish to Chromatic - Is Skipped
145
+ if : ${{ env.HAVE_CHROMATIC_PROJECT_TOKEN == 'true' }}
146
+ run : |
147
+ echo "secrets.CHROMATIC_PROJECT_TOKEN not existing, chromatic did not publish"
142
148
143
149
- name : Package storybook files
144
150
uses : actions/upload-artifact@v4 # provide nice artifact
You can’t perform that action at this time.
0 commit comments