use GHA for pushing page #2
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: 'publish_book' | |
on: | |
push: | |
branches: | |
- "main" | |
jobs: | |
publish_book: | |
runs-on: ubuntu-latest | |
permissions: | |
pages: write | |
id-token: write | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: prefix-dev/[email protected] | |
with: | |
pixi-version: v0.27.1 | |
environments: doc | |
- name: Build and publish the book | |
run: pixi run -e doc build-book | |
# Upload the book's HTML as an artifact | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v2 | |
with: | |
path: "book/_build/html" | |
# Deploy the book's HTML to GitHub Pages | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v2 | |