Skip to content

Update API docs

Update API docs #67

Workflow file for this run

name: Docs
run-name: Update API docs
on:
workflow_run:
workflows: [CI]
types: [completed]
branches: [master]
push:
branches: [master]
paths:
- ktreesitter/README.md
concurrency:
cancel-in-progress: true
group: ${{github.workflow}}-${{github.ref_name}}
permissions:
pages: write
id-token: write
jobs:
docs:
runs-on: ubuntu-latest
name: Publish docs on GitHub pages
if: >-
github.event_name == 'push' ||
github.event.workflow_run.conclusion == 'success'
environment:
name: github-pages
url: ${{steps.deployment.outputs.page_url}}
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
submodules: true
- name: Set up Java
uses: actions/setup-java@v5
with:
distribution: temurin
java-version: 17
cache: gradle
cache-dependency-path: |
gradle/libs.versions.toml
gradle/wrapper/gradle-wrapper.properties
- name: Cache Kotlin/Native dependencies
uses: actions/cache@v5
with:
path: ~/.konan
key: konan-${{runner.os}}-${{runner.arch}}-2.2.21
- name: Set up cross compilation
run: |-
sudo apt-get update
sudo apt-get install -qy {binutils,gcc}-aarch64-linux-gnu
- name: Build documentation
run: >-
./gradlew --no-daemon -P "cmake.version=4.1.2"
generateFiles :ktreesitter:dokkaGeneratePublicationHtml
- name: Upload pages artifact
uses: actions/upload-pages-artifact@v5
with:
path: ktreesitter/build/dokka/html
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v5