From 15ea25448f62a12771abbe9018b1ef0aac29f7d5 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 28 Mar 2022 01:27:30 +0200 Subject: [PATCH 1/4] Fix accidentally wrapped line in the docs workflow --- .github/workflows/docs_update.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/docs_update.yml b/.github/workflows/docs_update.yml index e62fd66c10..28b26aeb8a 100644 --- a/.github/workflows/docs_update.yml +++ b/.github/workflows/docs_update.yml @@ -36,5 +36,4 @@ jobs: echo "$DOCS_WEBSITE_KEY" > "$HOME/.ssh/docs_website_key" chmod 600 "$HOME/.ssh/docs_website_key" echo "$DOCS_WEBSITE_SSH_CONFIG" > "$HOME/.ssh/config" - rsync --checksum --compress --delete --recursive --verbose - out/html/ wxdocs:public_html/latest/ + rsync --checksum --compress --delete --recursive --verbose out/html/ wxdocs:public_html/latest/ From 20b8ba17735d58e1135679513e9e2c0e17e64c69 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 27 Mar 2022 18:13:48 +0200 Subject: [PATCH 2/4] Add extra script to the docs created in GitHub Actions workflow This was done by the cron job running in docs.wxwidgets.org before, so keep doing it here. --- .github/workflows/docs_update.yml | 6 ++++++ docs/doxygen/custom_footer.html | 4 +++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docs_update.yml b/.github/workflows/docs_update.yml index 28b26aeb8a..db73c4e4f2 100644 --- a/.github/workflows/docs_update.yml +++ b/.github/workflows/docs_update.yml @@ -20,6 +20,12 @@ jobs: run: | sudo apt-get -q -o=Dpkg::Use-Pty=0 -y install doxygen graphviz + - name: Customize for online docs + working-directory: docs/doxygen + run: | + sed -i'' -e "s@@@" \ + custom_footer.html + - name: Generate documentation working-directory: docs/doxygen run: | diff --git a/docs/doxygen/custom_footer.html b/docs/doxygen/custom_footer.html index 3f0f302765..7bacc10432 100644 --- a/docs/doxygen/custom_footer.html +++ b/docs/doxygen/custom_footer.html @@ -19,6 +19,8 @@ + + - \ No newline at end of file + From fe944dec684539b8405a8ee971929119e25f8d51 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 28 Mar 2022 10:55:08 +0200 Subject: [PATCH 3/4] Only deploy the documentation from master Don't do it for pull requests. This check also seems to render the check for the repository owner unnecessary, so drop it instead of keeping both. --- .github/workflows/docs_update.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docs_update.yml b/.github/workflows/docs_update.yml index db73c4e4f2..fbdb711354 100644 --- a/.github/workflows/docs_update.yml +++ b/.github/workflows/docs_update.yml @@ -32,7 +32,7 @@ jobs: ./regen.sh php - name: Upload - if: github.repository_owner == 'wxWidgets' + if: github.ref == 'refs/heads/master' working-directory: docs/doxygen env: DOCS_WEBSITE_KEY: ${{secrets.DOCS_WEBSITE_KEY}} From 4179d13dabb6a0ab6ef7746cb2b6207f2960cbde Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 28 Mar 2022 10:56:32 +0200 Subject: [PATCH 4/4] Fail the documentation build if there are any Doxygen warnings Check for Doxygen warnings, that are, for the most part, actually errors, to ensure that they don't creep back in after they were recently fixed. --- .github/workflows/docs_update.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/docs_update.yml b/.github/workflows/docs_update.yml index fbdb711354..0174d15281 100644 --- a/.github/workflows/docs_update.yml +++ b/.github/workflows/docs_update.yml @@ -30,6 +30,13 @@ jobs: working-directory: docs/doxygen run: | ./regen.sh php + if [[ -s doxygen.log ]]; then + echo '*** There were warnings during docs generation: ***' + echo '-----------------------------------------------------------' + cat doxygen.log + echo '-----------------------------------------------------------' + exit 1 + fi - name: Upload if: github.ref == 'refs/heads/master'