Bump eisvogel from 5dddcb3
to d22cbd7
(#72)
#124
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: Build Documents | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
ci: | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: shallow clone submodules | |
run: git submodule update --init --recursive --depth=1 | |
- name: Install system packages | |
run: sudo apt-get update && sudo apt-get install -y fonts-noto-cjk | |
- name: Setup micromamba | |
uses: mamba-org/setup-micromamba@v2 | |
with: | |
environment-file: environment.yml | |
init-shell: bash | |
cache-environment: true | |
post-cleanup: 'all' | |
- name: Build documents | |
shell: micromamba-shell {0} | |
run: bash -c 'cd examples && bash build-examples.sh && cd ..' | |
- name: Build homepage | |
shell: micromamba-shell {0} | |
if: ${{ github.ref == 'refs/heads/main' }} | |
run: pandoc --toc --template=GitHub.html5 ./examples/index.md -o ./examples/index.html | |
- name: Setup Pages | |
if: ${{ github.ref == 'refs/heads/main' }} | |
id: pages | |
uses: actions/configure-pages@v5 | |
- name: Upload page artifact | |
if: ${{ github.ref == 'refs/heads/main' }} | |
uses: actions/upload-pages-artifact@v3 | |
with: | |
path: ./examples | |
# Deploy pages | |
deploy: | |
needs: ci | |
if: ${{ github.ref == 'refs/heads/main' }} | |
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment | |
permissions: | |
pages: write # to deploy to Pages | |
id-token: write # to verify the deployment originates from an appropriate source | |
actions: read # to download an artifact uploaded by `actions/upload-pages-artifact@v3` | |
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 |