mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-05-14 20:48:00 +00:00
Automatically run workflows to generate API docs PRs (#11749)
This commit is contained in:
parent
9559d25da9
commit
df8dd41a8e
2 changed files with 17 additions and 17 deletions
16
.github/workflows/publish-c-apidocs.yml
vendored
16
.github/workflows/publish-c-apidocs.yml
vendored
|
|
@ -1,6 +1,8 @@
|
|||
name: Update C/C++ API Docs
|
||||
on:
|
||||
workflow_dispatch
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
|
|
@ -10,7 +12,7 @@ jobs:
|
|||
- uses: actions/checkout@v2
|
||||
- name: Install doxygen and dependencies
|
||||
run: |
|
||||
sudo apt update
|
||||
sudo apt update
|
||||
sudo apt-get install libclang-9-dev
|
||||
sudo apt-get install libclang-cpp9
|
||||
wget https://www.doxygen.nl/files/doxygen-1.9.2.linux.bin.tar.gz
|
||||
|
|
@ -26,18 +28,16 @@ jobs:
|
|||
- uses: actions/checkout@v2
|
||||
with:
|
||||
ref: gh-pages
|
||||
clean: false
|
||||
clean: false
|
||||
- name: Move API docs into target area
|
||||
run: |
|
||||
rm -rf docs/api/c
|
||||
mv build/doxygen/html docs/api/c
|
||||
mv build/doxygen/html docs/api/c
|
||||
- name: Create Pull Request
|
||||
uses: peter-evans/create-pull-request@v3
|
||||
with:
|
||||
branch: gh-pages-pr
|
||||
base: gh-pages
|
||||
title: '[Automated]: Update C/C++ API docs'
|
||||
commit-message: 'Update C/C++ API docs to commit ${{ steps.vars.outputs.sha_short }}'
|
||||
add-paths: docs/api/c
|
||||
|
||||
|
||||
commit-message: 'Update C/C++ API docs to commit ${{ steps.vars.outputs.sha_short }}'
|
||||
add-paths: docs/api/c
|
||||
|
|
|
|||
18
.github/workflows/publish-python-apidocs.yml
vendored
18
.github/workflows/publish-python-apidocs.yml
vendored
|
|
@ -1,6 +1,8 @@
|
|||
name: Update Python API Docs
|
||||
on:
|
||||
workflow_dispatch
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
|
|
@ -10,7 +12,7 @@ jobs:
|
|||
- uses: actions/checkout@v2
|
||||
- name: Install tools
|
||||
run: |
|
||||
sudo apt update
|
||||
sudo apt update
|
||||
sudo apt-get install pip
|
||||
sudo apt-get install graphviz
|
||||
- name: Install dependencies
|
||||
|
|
@ -23,26 +25,24 @@ jobs:
|
|||
- name: Generate Python docs with Sphinx
|
||||
run: |
|
||||
cd tools/doc
|
||||
./builddoc.sh /usr/bin ../.. ../../build
|
||||
./builddoc.sh /usr/bin ../.. ../../build
|
||||
- name: Set vars
|
||||
id: vars
|
||||
run: echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
ref: gh-pages
|
||||
clean: false
|
||||
clean: false
|
||||
- name: Move API docs into target area
|
||||
run: |
|
||||
ls docs/api
|
||||
rm -rf docs/api/python
|
||||
mv build/docs/inference/html docs/api/python
|
||||
mv build/docs/inference/html docs/api/python
|
||||
- name: Create Pull Request
|
||||
uses: peter-evans/create-pull-request@v3
|
||||
with:
|
||||
branch: gh-pages-pr-python-docs
|
||||
base: gh-pages
|
||||
title: '[Automated]: Update Python API docs'
|
||||
commit-message: 'Update Python API docs to commit ${{ steps.vars.outputs.sha_short }}'
|
||||
add-paths: docs/api/python
|
||||
|
||||
|
||||
commit-message: 'Update Python API docs to commit ${{ steps.vars.outputs.sha_short }}'
|
||||
add-paths: docs/api/python
|
||||
|
|
|
|||
Loading…
Reference in a new issue