moa/.github/workflows/deploy-docs.yaml

51 lines
1.2 KiB
YAML
Raw Normal View History

2023-05-01 04:33:02 +00:00
name: deploy-docs
on:
push:
branches:
- main
permissions:
contents: read
pages: write
id-token: write
jobs:
build-docs:
runs-on: ubuntu-latest
2023-05-01 05:10:49 +00:00
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
2023-05-01 04:33:02 +00:00
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
2023-05-01 05:39:05 +00:00
target: wasm32-unknown-unknown
2023-05-01 06:11:52 +00:00
- uses: jetli/wasm-bindgen-action@v0.2.0
2023-05-01 04:33:02 +00:00
2023-05-01 04:39:50 +00:00
- name: Install dependencies
2023-05-01 05:39:05 +00:00
run: |
sudo apt-get install -y alsa-base libasound2-dev libxkbcommon-dev
cargo install just
- name: Make build directory
run: mkdir build
- name: Build Pixels frontend
run: |
cd emulator/frontends/pixels
just build moa-genesis
cp -R dist/* ../../../build
2023-05-01 04:39:50 +00:00
2023-05-01 04:33:02 +00:00
- name: Build docs
2023-05-01 05:39:05 +00:00
run: |
cargo doc --document-private-items --workspace
cp -R target/doc build
2023-05-01 04:33:02 +00:00
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
2023-05-01 06:19:01 +00:00
path: build
2023-05-01 04:33:02 +00:00
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1