TOKENS BRO... TOKENS #23
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
| name: Site Publisher | |
| on: | |
| push: | |
| branches: [ "master" ] | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| jobs: | |
| build: | |
| name: Generate site | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest] | |
| scala: [3.2.2] | |
| java: [temurin@8] | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - name: Checkout current branch (full) | |
| uses: actions/checkout@v3 | |
| with: | |
| fetch-depth: 0 | |
| - name: Download Java (temurin@8) | |
| id: download-java-temurin-8 | |
| uses: typelevel/download-java@v2 | |
| with: | |
| distribution: temurin | |
| java-version: 17 | |
| - name: Setup Java (temurin@8) | |
| uses: actions/setup-java@v3 | |
| with: | |
| distribution: jdkfile | |
| java-version: 17 | |
| jdkFile: ${{ steps.download-java-temurin-8.outputs.jdkFile }} | |
| - name: Setup SBT | |
| uses: Jtalk/setup-sbt@v2.0.0 | |
| with: | |
| version: 1.10.6 | |
| - name: Generate site | |
| run: sbt '++ ${{ matrix.scala }}' web/fullBuild | |
| - name: Setup Pages | |
| id: pages | |
| uses: actions/configure-pages@v5 | |
| - name: Upload artifact | |
| # Automatically uploads an artifact from the './_site' directory by default | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: web/target/webpage | |
| # Deployment job | |
| deploy: | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| runs-on: ubuntu-latest | |
| needs: build | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 | |