Alter router display to use different characters #49
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: docs | |
on: | |
workflow_dispatch: | |
push: | |
branches: [main] | |
permissions: | |
contents: read | |
id-token: write | |
pages: write | |
concurrency: | |
group: "${{ github.workflow }}-${{ github.ref }}" | |
cancel-in-progress: true | |
env: | |
SCCACHE_GHA_ENABLED: "true" | |
SCCACHE_GHA_VERSION: "1" | |
jobs: | |
docs: | |
runs-on: ubuntu-22.04 | |
defaults: | |
run: | |
shell: nix develop .#docs --command bash {0} | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install Nix | |
uses: DeterminateSystems/nix-installer-action@v13 | |
- name: Setup Nix cache | |
uses: DeterminateSystems/magic-nix-cache-action@v7 | |
- name: Configure SCCache | |
uses: actions/github-script@v7 | |
with: | |
script: | | |
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL); | |
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN); | |
- name: Initialize Nix shell | |
run: nix develop .#docs | |
- name: Build docs | |
run: | | |
set -eufo pipefail | |
cargo doc --no-deps | |
rm target/doc/.lock | |
echo '<meta http-equiv="refresh" content="0; url=wayfind/index.html">' > target/doc/index.html | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v3 | |
with: | |
path: target/doc | |
retention-days: 30 | |
- name: Show SCCache stats | |
if: always() && !cancelled() | |
run: sccache --show-stats | |
deploy: | |
needs: docs | |
runs-on: ubuntu-22.04 | |
environment: | |
name: github-pages | |
url: "${{ steps.deployment.outputs.page_url }}" | |
steps: | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v4 |