Skip to content

Commit 5cc916b

Browse files
snomiaoclaude
andauthored
[ci] Restrict chromatic workflow to version-bump-* PRs and manual triggers (#5167)
- Remove automatic trigger on push to main - Add workflow_dispatch for manual triggering - Add conditional to only run for PRs from version-bump-* branches - Reduces unnecessary Chromatic builds on regular PRs 🤖 Generated with [Claude Code](https://claude.ai/code) Co-authored-by: Claude <[email protected]>
1 parent c752553 commit 5cc916b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

.github/workflows/chromatic.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,15 @@ name: 'Chromatic'
33
# - [Automate Chromatic with GitHub Actions • Chromatic docs]( https://www.chromatic.com/docs/github-actions/ )
44

55
on:
6-
push:
7-
branches: [main]
6+
workflow_dispatch: # Allow manual triggering
87
pull_request:
98
branches: [main]
109

1110
jobs:
1211
chromatic-deployment:
1312
runs-on: ubuntu-latest
13+
# Only run for PRs from version-bump-* branches or manual triggers
14+
if: github.event_name == 'workflow_dispatch' || startsWith(github.head_ref, 'version-bump-')
1415
permissions:
1516
pull-requests: write
1617
issues: write

0 commit comments

Comments
 (0)