Skip to content

Commit

Permalink
add blanket handler (will fail) and add workflow yml
Browse files Browse the repository at this point in the history
  • Loading branch information
ndelangen committed Sep 23, 2021
1 parent 6e3e113 commit c29f7d0
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/chromatic-workflow_run.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: "Chromatic (workflow_run)"
on:
workflow_run:
workflows:
- "Chromatic (manual)"
types:
- completed

jobs:
chromatic:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-node@v1
with:
node-version: '14.x'
- uses: actions/checkout@v1
- name: install
run: yarn && git status --porcelain
- name: prep package
run: ./scripts/rename.js storybook-chromatic
- name: run chromatic
run: yarn chromatic
env:
CHROMATIC_PROJECT_TOKEN: gcaw1ai2dgo
4 changes: 4 additions & 0 deletions action-src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ const getBuildInfo = (event: typeof context) => {
slug: repository.full_name,
};
}
case 'workflow_run': {
console.log(event.payload);
return {};
}
case 'workflow_dispatch': {
const { ref, sha } = event.payload.inputs;

Expand Down

0 comments on commit c29f7d0

Please sign in to comment.