diff --git a/.github/workflows/ci_cd.yml b/.github/workflows/ci_cd.yml index c3575df5601..9b93ee54369 100644 --- a/.github/workflows/ci_cd.yml +++ b/.github/workflows/ci_cd.yml @@ -814,6 +814,7 @@ jobs: uses: actions/checkout@v3 with: ref: gh-pages + path: gh-pages - name: Checkout automations from repository uses: actions/checkout@v3 @@ -824,12 +825,12 @@ jobs: if: github.event_name == 'push' run: | mv /tmp/docs /tmp/gh-pages - mv _preview /tmp/gh-pages/_preview + mv gh-pages/_preview /tmp/gh-pages/_preview - name: Replace preview of current PR if: github.event_name == 'pull_request' run: | - cp -r . /tmp/gh-pages + cp -r gh-pages /tmp/gh-pages sudo rm -rf /tmp/gh-pages/_preview/${{ github.event.pull_request.number }} mv /tmp/docs /tmp/gh-pages/_preview/${{ github.event.pull_request.number }} diff --git a/documentation/meta/ci_cd/jobs/documentation.md b/documentation/meta/ci_cd/jobs/documentation.md index b168122e08a..11f14bb8763 100644 --- a/documentation/meta/ci_cd/jobs/documentation.md +++ b/documentation/meta/ci_cd/jobs/documentation.md @@ -54,6 +54,9 @@ Documentation is only emitted if all the following conditions are met. that their changes are valid, or were skipped, implying that they have no changes. +A comment is also published linking to the generated preview, and any new or +modified pages. + ## `clean-gh-pages` This job is executed when a PR is closed