Skip to content

Updated website workflows. #5

Updated website workflows.

Updated website workflows. #5

name: Deploy website to GitHub Pages
on:
push:
branches:
- main
paths:
- '.github/workflows/deploy-website.yml'
- './website/**'
permissions:
contents: write
defaults:
run:
working-directory: './website/'
jobs:
deploy:
name: Deploy to GitHub Pages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 20
cache: npm
cache-dependency-path: './website/package-lock.json'
- name: Install dependencies
run: npm ci
- name: Build website
run: npm run build
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
# Build output to publish to the `gh-pages` branch:
publish_dir: ./website/build
# The following lines assign commit authorship to the official
# GH-Actions bot for deploys to `gh-pages` branch:
user_name: github-actions[bot]
user_email: github-actions[bot]@users.noreply.github.com