From 487aa4b7b4e71e0c7bfe3611a4dec50b1ec24a44 Mon Sep 17 00:00:00 2001 From: Daniel Chappuis Date: Tue, 30 Apr 2024 07:28:13 +0200 Subject: [PATCH] Add github action to build documentation --- .github/workflows/publish-documentation.yml | 40 +++++++++++++++++++++ .github/workflows/release.yml | 4 +-- 2 files changed, 42 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/publish-documentation.yml diff --git a/.github/workflows/publish-documentation.yml b/.github/workflows/publish-documentation.yml new file mode 100644 index 00000000..f2944352 --- /dev/null +++ b/.github/workflows/publish-documentation.yml @@ -0,0 +1,40 @@ +# Build the Doxygen documentation (User manual and API reference) and publish it to www.reactphysics3d.com website +name: Publish Documentation + +# Controls when the action will run. Triggers the workflow on push +on: + push: + branches: + - documentation + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + documentation: + name: Build/Publish Documentation + runs-on: ubuntu-latest + #needs: [build-and-test] + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install cmake doxygen + cmake --version + doxygen --version + + - name: CMake Configure + shell: bash + run: | + mkdir build + cmake \ + -S . \ + -B build \ + -DRP3D_GENERATE_DOCUMENTATION=True \ + -DRP3D_COMPILE_TESTS=False \ + -DRP3D_COMPILE_TESTBED=False + + - name: BuildĀ Documentation + shell: bash + run: cmake --build build/ diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c34602d2..3a913ab2 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -19,12 +19,12 @@ jobs: create-release: name: Create Release runs-on: ubuntu-latest - #needs: [build-and-test] + needs: [build-and-test] steps: - name: Checkout uses: actions/checkout@v4 - - name: Create Release + - name: Build Documentation uses: docker://antonyurchenko/git-release:v6 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}