From af3573be1c04e68a996ceaa39d59a702bf5541e8 Mon Sep 17 00:00:00 2001 From: Tim Martin <38798827+tmartin-gh@users.noreply.github.com> Date: Thu, 16 Jan 2025 12:30:20 -0800 Subject: [PATCH] Update build_docs actions to newest. Add CI_RUN_DATETIME in version.rst. (#829) --- .github/workflows/build-docs.yml | 18 +++++++++--------- docs_input/conf.py.in | 1 + docs_input/version.rst | 1 + 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build-docs.yml b/.github/workflows/build-docs.yml index b430b47bd..4461ff9e4 100644 --- a/.github/workflows/build-docs.yml +++ b/.github/workflows/build-docs.yml @@ -21,7 +21,7 @@ on: branches: ["main"] # Allows you to run this workflow manually from the Actions tab - workflow_dispatch: + workflow_dispatch: # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages permissions: @@ -38,13 +38,13 @@ concurrency: jobs: Authorization: name: Authorization - runs-on: blossom + runs-on: blossom outputs: args: ${{ env.args }} - + # This job only runs for pull request merges or manually via the Actions tab if: | - contains( 'cliffburdick,awthomp,tbensonatl,tylera-nvidia,luitjens,tmartin-gh,', format('{0},', github.actor)) + contains( 'cliffburdick,awthomp,tbensonatl,tylera-nvidia,luitjens,tmartin-gh,', format('{0},', github.actor)) steps: - name: Check if comment is issued by authorized person run: blossom-ci @@ -52,7 +52,7 @@ jobs: OPERATION: 'AUTH' REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }} REPO_KEY_DATA: ${{ secrets.BLOSSOM_KEY }} - + deploy: name: Deploy Github Pages needs: [Authorization] @@ -67,7 +67,7 @@ jobs: password: ${{ secrets.DOCS_TOKEN }} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Build Docs run: | mkdir build @@ -75,12 +75,12 @@ jobs: cmake .. -DMATX_BUILD_DOCS=ON make - name: Setup Pages - uses: actions/configure-pages@v3 + uses: actions/configure-pages@v5 - name: Upload artifact - uses: actions/upload-pages-artifact@v2 + uses: actions/upload-pages-artifact@v3 with: path: 'build/docs_input/sphinx/' - name: Deploy to GitHub Pages id: deployment - uses: actions/deploy-pages@v2 + uses: actions/deploy-pages@v4 diff --git a/docs_input/conf.py.in b/docs_input/conf.py.in index d6be625a7..12713b416 100644 --- a/docs_input/conf.py.in +++ b/docs_input/conf.py.in @@ -194,6 +194,7 @@ epub_exclude_files = ['search.html'] rst_epilog = f""" .. |ProjectVersion| replace:: {version} .. |ProjectRelease| replace:: {release} +.. |CI_RUN_DATETIME| replace:: {datetime.datetime.now()} """ ci_env_list = [ diff --git a/docs_input/version.rst b/docs_input/version.rst index c0d04b0fe..4698a06f9 100644 --- a/docs_input/version.rst +++ b/docs_input/version.rst @@ -9,5 +9,6 @@ Version Info GITHUB_REF_NAME: |GITHUB_REF_NAME| GITHUB_SHA: |GITHUB_SHA| CI_COMMIT_URL: |CI_COMMIT_URL| + CI_RUN_DATETIME: |CI_RUN_DATETIME| ======================== ========================