publish-docs #3
This file contains 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: publish-docs | |
on: workflow_dispatch | |
jobs: | |
build-and-deploy-storybooks: | |
runs-on: ubuntu-latest | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
concurrency: | |
group: "pages" | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '16' | |
- name: Build docs Storybooks | |
run: | | |
npm install | |
npm run storybook-web-docs | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v2 | |
with: | |
# Upload entire repository | |
path: './docs/' | |
name: docs | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v2 | |
with: | |
artifact_name: 'docs' | |
github-token: ${{ secrets.GITHUB_TOKEN }} |