Skip to content

Commit

Permalink
feat: add storybook preview to pr links
Browse files Browse the repository at this point in the history
  • Loading branch information
fbwoolf authored and kyranjamie committed Mar 18, 2024
1 parent e49e7ec commit 0e0ca6f
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 20 deletions.
22 changes: 21 additions & 1 deletion .github/workflows/build-extension.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,32 @@ jobs:
name: leather-${{ matrix.target }}-${{ env.SHORT_SHA }}
path: dist

chromatic:
runs-on: ubuntu-latest
outputs:
storybook_url: ${{ steps.chromatic.outputs.storybookUrl }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: ./.github/actions/provision

- name: Deploy to Chromatic
id: chromatic
uses: chromaui/action@latest
with:
autoAcceptChanges: 'main'
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
token: ${{ secrets.GITHUB_TOKEN }}

set-download-link:
if: github.repository == 'leather-wallet/extension' && github.actor != 'dependabot[bot]'
runs-on: ubuntu-latest
needs:
- pre-run
- build
- chromatic
steps:
- name: Extract branch name
shell: bash
Expand All @@ -75,5 +95,5 @@ jobs:

- uses: kyranjamie/[email protected]
with:
header: '> Try out this version of Leather — [Extension build](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}), [Test report](https://leather-wallet.github.io/playwright-reports/${{ steps.extract_branch.outputs.branch }})'
header: '> Try out this version of Leather — [Extension build](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}), [Test report](https://leather-wallet.github.io/playwright-reports/${{ steps.extract_branch.outputs.branch }}), [Storybook preview](${{ needs.chromatic.outputs.storybook_url }})'
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19 changes: 0 additions & 19 deletions .github/workflows/chromatic.yml

This file was deleted.

0 comments on commit 0e0ca6f

Please sign in to comment.