Skip to content

More release.md tweaks #341

More release.md tweaks

More release.md tweaks #341

Workflow file for this run

name: pages
on:
push:
branches:
- master
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false
env:
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
RUSTFLAGS: "-D warnings"
RUSTUP_MAX_RETRIES: 10
SCCACHE_GHA_ENABLED: "true"
RUSTC_WRAPPER: "sccache"
jobs:
build:
if: github.repository == 'redbadger/crux'
runs-on: ubuntu-latest
steps:
- name: Checkout (latest)
uses: actions/checkout@v4
with:
path: latest
- name: Checkout (stable)
uses: actions/checkout@v4
with:
ref: book-stable
path: stable
- uses: dtolnay/rust-toolchain@stable
- name: Run sccache-cache
uses: mozilla-actions/[email protected]
- name: Setup mdBook
uses: jontze/action-mdbook@v3
with:
token: ${{secrets.GITHUB_TOKEN}}
use-linkcheck: true
use-admonish: true
- name: Setup Pages
id: pages
uses: actions/configure-pages@v5
- name: Build Documentation (latest)
working-directory: latest
run: cargo doc --all --no-deps
- name: Build Documentation (stable)
working-directory: stable
run: cargo doc --all --no-deps
- name: Build book (latest)
working-directory: latest/docs
run: mdbook build
- name: Build book (stable)
working-directory: stable/docs
run: mdbook build
- name: Move outputs
run: |
set -e
mkdir -p ./public/latest_master
mv latest/target/doc ./public/latest_master/master_api_docs
mv latest/docs/book/html/* ./public/latest_master/
mv stable/target/doc ./public/master_api_docs
mv stable/docs/book/html/* ./public/
- name: Upload GitHub Pages artifact
id: deployment
uses: actions/upload-pages-artifact@v3
with:
path: public/
deploy:
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 to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4