Skip to content

Commit

Permalink
Create website deployment workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
garryod committed Aug 15, 2023
1 parent 46841fc commit 132ab75
Showing 1 changed file with 56 additions and 0 deletions.
56 changes: 56 additions & 0 deletions .github/workflows/website.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
on:
push:
pull_request:

name: Website

jobs:
build:
name: Build Examples
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v3

- name: Install stable toolchain
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
target: wasm32-unknown-unknown

- name: Install trunk
uses: jetli/[email protected]
with:
toolchain: stable
components: clippy

- name: Rust Cache
uses: Swatinem/[email protected]

- name: Build Website
run: |
cd website
trunk build
- name: Upload GitHub Pages artifact
uses: actions/[email protected]
with:
path: website/dist

deploy:
name: Deploy Pages
needs:
- build
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy GitHub Pages site
id: deployment
uses: actions/[email protected]
with:
token: ${{ github.token }}

0 comments on commit 132ab75

Please sign in to comment.