Skip to content

Commit

Permalink
Use peaceiris/actions-gh-pages@v3 plugin to deploy storybook
Browse files Browse the repository at this point in the history
  • Loading branch information
bragaru-i committed Jan 26, 2024
1 parent d48d7c3 commit eb76f5c
Showing 1 changed file with 21 additions and 16 deletions.
37 changes: 21 additions & 16 deletions .github/workflows/storybook-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,28 @@ on:
push:
branches:
- main

jobs:
deploy-storybook:
deploy:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- name: Checkout repository
uses: actions/checkout@v2

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 14

- name: Install dependencies
run: npm install

- name: Build site
run: npm run predeploy

- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
node-version: 18
- run: npm ci --unsafe-perm
- run: npm test
- run: npm run predeploy
- run: git config --global user.email "bragaruion@gmail.com"
- run: git config --global user.name "Bragaru Ion"
- name: Deploy with gh-pages
run: |
git remote set-url origin https://git:${GHUB_TOKEN}@github.com/${GHUB_REPOSITORY}.git
npm run deploy
env:
GITHUB_TOKEN: ${{ secrets.GHUB_TOKEN }}
github_token: ${{ secrets.GHUB_TOKEN }}
publish_dir: ./gh-pages-dist

0 comments on commit eb76f5c

Please # to comment.