update build.sh #6
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: Documentation | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| documentation: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| pages: write # needed to publish to GitHub Pages | |
| id-token: write # required for GitHub Pages deployment | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Java | |
| uses: actions/setup-java@v4 | |
| with: | |
| distribution: temurin | |
| java-version: 17 | |
| cache: maven | |
| server-id: central | |
| server-username: MAVEN_USERNAME | |
| server-password: MAVEN_PASSWORD | |
| - name: Build Java Project | |
| run: mvn clean package | |
| - name: Build Docs | |
| run: bash ./build.sh | |
| - name: Copy Javadocs into docs | |
| run: cp -r target/site/apidocs ./docs/.hyperbook/out/javadocs | |
| - name: Setup Pages | |
| uses: actions/configure-pages@v5 | |
| - name: Upload Docs artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: ./docs/.hyperbook | |
| - name: Deploy Javadocs to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |