onnxruntime/.github/workflows/publish-java-apidocs.yml
Edward Chen bd142bfb04
Gradle clean up (#14973)
- Use java/gradlew directly in .github/workflows/publish-java-apidocs.yml.
- Remove use of deleted step from tools/ci_build/github/azure-pipelines/android-arm64-v8a-QNN-crosscompile-ci-pipeline.yml.
- Remove Gradle installations and PATH updates from Dockerfiles and scripts. Now Gradle wrapper is used so a system Gradle installation is not needed.
2023-03-10 10:50:32 -08:00

43 lines
1.2 KiB
YAML

name: Update Java API Docs
on:
push:
branches:
- main
workflow_dispatch:
jobs:
publish:
name: Generate Java docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'adopt'
- name: Build with Gradle
uses: gradle/gradle-build-action@v2
with:
build-root-directory: java
gradle-executable: java/gradlew
arguments: javadoc
- name: Set commit ID
id: vars
run: echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
- uses: actions/checkout@v2
with:
ref: gh-pages
clean: false
- name: Move API docs into target area
run: |
rm -rf docs/api/java
mv java/build/docs/javadoc docs/api/java
- name: Create Pull Request
uses: peter-evans/create-pull-request@v3
with:
branch: gh-pages-pr
base: gh-pages
title: '[Automated]: Update Java API docs'
commit-message: 'Update Java API docs to commit ${{ steps.vars.outputs.sha_short }}'
add-paths: docs/api/java