Skip to content

Generate site and push to GitHub pages #55

Generate site and push to GitHub pages

Generate site and push to GitHub pages #55

Workflow file for this run

name: Java CI with Maven
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: maven
- name: Build with Maven
run: ./mvnw -B verify javadoc:jar
- name: Publish to codecov
continue-on-error: true
if: always()
shell: bash
run: |-
curl --fail https://keybase.io/codecovsecurity/pgp_keys.asc | gpg --no-default-keyring \
--keyring trustedkeys.gpg --import
curl --fail -Os https://uploader.codecov.io/latest/linux/codecov
curl --fail -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM
curl --fail -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM.sig
gpgv codecov.SHA256SUM.sig codecov.SHA256SUM
shasum -a 256 -c codecov.SHA256SUM
chmod -v +x codecov
./codecov -v
site:
if: github.ref == 'refs/heads/main' && github.event_name != 'pull_request'
runs-on: ubuntu-latest
needs:
- build
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: maven
- name: Generate site
run: ./mvnw -B site
- name: Upload site
uses: actions/upload-pages-artifact@v2
with:
path: target/site
- name: Deploy site
id: site
uses: actions/deploy-pages@v2