wip #25
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: gh-pages | |
on: | |
push: | |
branches: ['main'] | |
workflow_dispatch: | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install Nix | |
uses: cachix/install-nix-action@v31 | |
with: | |
nix_path: nixpkgs=channel:nixpkgs-unstable | |
- name: Build Storybook | |
run: nix develop --command bash -c "npm i --legacy-peer-deps && npm run storybook:build" | |
- name: Build Vitest UI (@vitest/ui) | |
id: vitest | |
continue-on-error: true | |
run: nix develop --command bash -c "npm i --legacy-peer-deps && npm run ui:static" | |
- name: Move Vitest UI Reposrt | |
run: | | |
mv ./html/ ./storybook-static/html | |
- name: Build Vitest Coverate (@vitest/coverage-v8) | |
continue-on-error: true | |
run: nix develop --command bash -c "npm i --legacy-peer-deps && npm run coverage:static" | |
- name: Move Vitest Coverage Reposrt | |
continue-on-error: true | |
run: | | |
mv ./coverage/ ./storybook-static/coverage | |
- name: Deploy to GitHub Pages | |
uses: peaceiris/actions-gh-pages@v4 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./storybook-static |