Build Docs #25
Workflow file for this run
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 Docs | |
on: | |
release: | |
types: [ published ] | |
permissions: | |
contents: write | |
jobs: | |
dokka: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
packages: write | |
steps: | |
- name: Checkout latest code | |
uses: actions/checkout@v4 | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: 17 | |
distribution: 'zulu' | |
cache: 'gradle' | |
- name: Get the tag name | |
run: echo "VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV | |
- name: Build Dokka | |
run: ./gradlew dokkaHtm -Pversion=${{ env.VERSION }} | |
- name: Publish documentation | |
uses: JamesIves/github-pages-deploy-action@v4.6.1 | |
with: | |
branch: gh-pages | |
folder: build/dokka/html | |
target-folder: docs | |
commit-message: "doc: Add documentation for latest release: ${{ env.VERSION }}" |