Skip to content

Merge pull request #272 from lf-lang/v0.8.0 #209

Merge pull request #272 from lf-lang/v0.8.0

Merge pull request #272 from lf-lang/v0.8.0 #209

Workflow file for this run

# https://docusaurus.io/docs/deployment#triggering-deployment-with-github-actions
# Author: axmmisaka; WTFPL or BSD 3-clause
name: Deploy to GitHub Pages
on:
pull_request:
push:
branches:
- main
# Review gh actions docs if you want to further define triggers, paths, etc
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on
permissions:
contents: write
pages: write
id-token: write
jobs:
build:
name: Deploy to GitHub Pages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: yarn
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Build website
run: yarn build
- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
path: ./build
# Deployment job
deploy:
if: ${{ github.event_name == 'push' && github.ref_name == 'main' }}
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v3
# TODO: Deploy to some third-party place for preview?