From 40e6fc9120b88151afde3ceb734ab0e3ef1dd536 Mon Sep 17 00:00:00 2001 From: biancabnd Date: Tue, 30 Jan 2024 13:00:17 +0100 Subject: [PATCH 1/2] Commit and update documentation on push --- .github/workflows/build_docs.yaml | 27 +++++++++++++++------------ .github/workflows/upload-debians.yaml | 2 +- .gitignore | 1 + 3 files changed, 17 insertions(+), 13 deletions(-) diff --git a/.github/workflows/build_docs.yaml b/.github/workflows/build_docs.yaml index 1b23ab31..c927b2f7 100644 --- a/.github/workflows/build_docs.yaml +++ b/.github/workflows/build_docs.yaml @@ -1,16 +1,20 @@ name: Build Documentation on: - pull_request: - types: [opened, synchronize, reopened] - + # Runs on pushes targeting the default branch + push: + branches: ["main"] + jobs: build: runs-on: ubuntu-latest - + permissions: + contents: write steps: - name: Checkout code uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.ref }} - name: Set up Python uses: actions/setup-python@v5 @@ -25,6 +29,7 @@ jobs: - name: Install Doxygen run: | + cd .. wget https://www.doxygen.nl/files/doxygen-1.9.7.linux.bin.tar.gz tar -xzvf doxygen-1.9.7.linux.bin.tar.gz cd doxygen-1.9.7 @@ -34,11 +39,9 @@ jobs: run: | make -C docs html # This assumes your Sphinx configuration is in a 'docs' folder - # - name: Deploy to GitHub Pages (optional) - # Uncomment the following lines if you want to deploy to GitHub Pages - # run: | - # git checkout gh-pages - # cp -r docs/_build/html/* . - # git add . - # git commit -m "Update documentation" - # git push origin gh-pages + - name: Add and commit + uses: EndBug/add-and-commit@v9.1.4 + with: + author_name: UMLDev Clang Robot + author_email: dev@unmanned.life + message: 'Update documentation' diff --git a/.github/workflows/upload-debians.yaml b/.github/workflows/upload-debians.yaml index 44677f9b..8ec969ec 100644 --- a/.github/workflows/upload-debians.yaml +++ b/.github/workflows/upload-debians.yaml @@ -2,7 +2,7 @@ name: Build Debians on: push: tags: - - 'v*' + - '*' jobs: build_debians: diff --git a/.gitignore b/.gitignore index c39c1b98..6d8fadbd 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ docs/doxyoutput docs/api +docs/_build/doctrees .pre-commit-config.yaml \ No newline at end of file From a49e47db95cefa33b98c957d05e248e79d37586a Mon Sep 17 00:00:00 2001 From: biancabnd Date: Tue, 30 Jan 2024 14:57:30 +0100 Subject: [PATCH 2/2] Update workflow --- .github/workflows/build_docs.yaml | 4 ++-- .github/workflows/upload-debians.yaml | 5 ----- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build_docs.yaml b/.github/workflows/build_docs.yaml index c927b2f7..0b6c3ff2 100644 --- a/.github/workflows/build_docs.yaml +++ b/.github/workflows/build_docs.yaml @@ -14,7 +14,7 @@ jobs: - name: Checkout code uses: actions/checkout@v4 with: - ref: ${{ github.event.pull_request.head.ref }} + ref: main - name: Set up Python uses: actions/setup-python@v5 @@ -42,6 +42,6 @@ jobs: - name: Add and commit uses: EndBug/add-and-commit@v9.1.4 with: - author_name: UMLDev Clang Robot + author_name: UMLDev Robot author_email: dev@unmanned.life message: 'Update documentation' diff --git a/.github/workflows/upload-debians.yaml b/.github/workflows/upload-debians.yaml index 8ec969ec..690c37c1 100644 --- a/.github/workflows/upload-debians.yaml +++ b/.github/workflows/upload-debians.yaml @@ -13,11 +13,6 @@ jobs: - uses: actions/checkout@v4 with: path: psdk_ros2 - - uses: actions/checkout@v4 - with: - repository: dji-sdk/Payload-SDK - ref: 3.5 - path: Payload-SDK - name: ROS 2 Build Debian Package id: build run: |