From b17460303a5b2d4a1860d86ca722fb27a4581ac7 Mon Sep 17 00:00:00 2001 From: GeoJulien Date: Thu, 23 Feb 2023 12:47:37 +0100 Subject: [PATCH 1/3] Bump pre-commit --- requirements/development.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements/development.txt b/requirements/development.txt index 41aca24d..d47dace6 100644 --- a/requirements/development.txt +++ b/requirements/development.txt @@ -5,6 +5,6 @@ black feedparser>=6.0,<6.1 flake8>=4,<6.1 -pre-commit>=2.10,<3.1 +pre-commit>=3,<3.2 pytest-cov==4.0.* validator-collection>=1.5,<1.6 From 2243401645785a65c11310593fb06114b2ffe855 Mon Sep 17 00:00:00 2001 From: GeoJulien Date: Thu, 23 Feb 2023 12:56:15 +0100 Subject: [PATCH 2/3] Bump doc depdencies --- requirements.txt | 3 --- requirements/documentation.txt | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/requirements.txt b/requirements.txt index 2d521a05..75766a0b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,3 @@ -setuptools -wheel - -r requirements/base.txt -e "." diff --git a/requirements/documentation.txt b/requirements/documentation.txt index 6780da46..ccd7cef2 100644 --- a/requirements/documentation.txt +++ b/requirements/documentation.txt @@ -1,6 +1,6 @@ # Documentation # ----------------------- mkdocs-bootswatch>=1,<2 -mkdocs-minify-plugin==0.5.* +mkdocs-minify-plugin==0.6.* pygments>=2.5,<3 pymdown-extensions>=7,<10 From 626fbcb6d1d428b656c12787f61987eac3f8e492 Mon Sep 17 00:00:00 2001 From: GeoJulien Date: Thu, 23 Feb 2023 12:56:25 +0100 Subject: [PATCH 3/3] Improve doc workflow --- .github/workflows/documentation.yml | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 50d45e1f..cb662141 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -13,6 +13,12 @@ on: tags: - "*" + pull_request: + branches: [main] + paths: + - ".github/workflows/documentation.yml" + - requirements/documentation.txt + # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages permissions: contents: read @@ -54,15 +60,26 @@ jobs: - name: Build static website run: mkdocs build --verbose + - name: Save build doc as artifact + uses: actions/upload-artifact@v3 + with: + name: documentation + path: site/ + if-no-files-found: error + retention-days: 30 + - name: Setup Pages uses: actions/configure-pages@v3 + if: github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main') - name: Upload artifact uses: actions/upload-pages-artifact@v1 + if: github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main') with: # Upload entire repository - path: site + path: site/ - name: Deploy to GitHub Pages id: deployment + if: github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main') uses: actions/deploy-pages@v1