fix: Broken links in documentation #277
This file contains hidden or 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
| # This workflow deploys the documentation site to GitHub Pages. | |
| name: Deploy site | |
| # This workflow only runs on the main branch when site files change. | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - "site/**" | |
| jobs: | |
| site: | |
| name: Build and deploy site | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| submodules: recursive | |
| - name: Set up build environment | |
| uses: ./.github/actions/setup-build-tools | |
| with: | |
| java: "true" | |
| r: "true" | |
| r-pandoc: "true" | |
| python: "true" | |
| bun: "true" | |
| - name: Run install goal | |
| env: | |
| R_KEEP_PKG_SOURCE: yes | |
| run: | | |
| mvn --batch-mode install \ | |
| -pl site -am -DskipTests -Pdocs | |
| timeout-minutes: 60 | |
| - name: Save site | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: site | |
| path: site/target/site/ | |
| - name: Copy R package into site | |
| run: | | |
| mkdir -p site/target/site/R | |
| cp lib/R/target/pathling_*.tar.gz site/target/site/R/ | |
| - name: Preserve helm directory from gh-pages | |
| run: | | |
| git fetch origin gh-pages:gh-pages || true | |
| if git show gh-pages:helm/index.yaml >/dev/null 2>&1; then | |
| git archive gh-pages helm | tar -x -C site/target/site/ | |
| fi | |
| - name: Deploy to GitHub Pages | |
| uses: peaceiris/actions-gh-pages@4f9cc6602d3f66b9c108549d475ec49e8ef4d45e # v4 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_dir: ./site/target/site |