From df2056aa3e7189bb6711be6dde6db36a0c33a625 Mon Sep 17 00:00:00 2001 From: Renata Imai Date: Tue, 26 Nov 2024 15:34:07 -0300 Subject: [PATCH] fix path to latest --- .github/workflows/documentation.yml | 34 ++++++++++++++++--- docs/source/_templates/navigation_header.html | 12 +++---- docs/source/conf.py | 2 +- docs/source/index.rst | 2 +- .../modeling_with_aequilibrae/index.rst | 2 +- .../development/softwaredevelopment.rst | 2 +- .../useful_information/version_history.rst | 2 +- 7 files changed, 41 insertions(+), 15 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 94c0c1036..ceb2b9515 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -74,7 +74,7 @@ jobs: AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} AWS_REGION: 'us-east-1' # optional: defaults to us-east-1 SOURCE_DIR: 'docs/build/html/' # optional: defaults to entire repository - DEST_DIR: 'dev/python/' # optional: defaults to entire repository + DEST_DIR: 'dev/${{ github.event.number }}/python/' # optional: defaults to entire repository - name: Upload home page to DEV on S3 if: ${{ (github.event_name == 'pull_request') && (env.HAS_SECRETS == 'true') }} @@ -87,32 +87,58 @@ jobs: AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} AWS_REGION: 'us-east-1' # optional: defaults to us-east-1 SOURCE_DIR: 'docs/build/html/' - DEST_DIR: 'dev/' # optional: defaults to entire repository + DEST_DIR: 'dev/${{ github.event.number }}/' # optional: defaults to entire repository - name: Upload python to DEVELOP on S3 if: ${{ (github.ref == 'refs/heads/develop') && (github.event_name == 'push') && (env.HAS_SECRETS == 'true') }} uses: jakejarvis/s3-sync-action@master with: - args: --acl public-read --follow-symlinks + args: --acl public-read --follow-symlinks --delete --exclude 'home.html' env: AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }} AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} AWS_REGION: 'us-east-1' # optional: defaults to us-east-1 SOURCE_DIR: 'docs/build/html/' # optional: defaults to entire repository + DEST_DIR: 'develop/python/' # optional: defaults to entire repository + + - name: Upload home page to DEVELOP on S3 + if: ${{ (github.ref == 'refs/heads/develop') && (github.event_name == 'push') && (env.HAS_SECRETS == 'true') }} + uses: jakejarvis/s3-sync-action@master + with: + args: --acl public-read --follow-symlinks --exclude '*' --include 'home.html' --include '_images/sponsor*' --include '_images/banner*' --include '_static/*' --include 'search*' --include 'genindex.html' --include '_sphinx_design_static/*' + env: + AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }} + AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + AWS_REGION: 'us-east-1' # optional: defaults to us-east-1 + SOURCE_DIR: 'docs/build/html/' DEST_DIR: 'develop/' # optional: defaults to entire repository - name: Upload python to LATEST on S3 if: ${{ (github.event_name == 'release') && (env.HAS_SECRETS == 'true') }} uses: jakejarvis/s3-sync-action@master with: - args: --acl public-read --follow-symlinks + args: --acl public-read --follow-symlinks --delete --exclude 'home.html' env: AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }} AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} AWS_REGION: 'us-east-1' # optional: defaults to us-east-1 SOURCE_DIR: 'docs/build/html/' # optional: defaults to entire repository + DEST_DIR: 'latest/python/' # optional: defaults to entire repository + + - name: Upload home page to LATEST on S3 + if: ${{ (github.event_name == 'release') && (env.HAS_SECRETS == 'true') }} + uses: jakejarvis/s3-sync-action@master + with: + args: --acl public-read --follow-symlinks --exclude '*' --include 'home.html' --include '_images/sponsor*' --include '_images/banner*' --include '_static/*' --include 'search*' --include 'genindex.html' --include '_sphinx_design_static/*' + env: + AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }} + AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + AWS_REGION: 'us-east-1' # optional: defaults to us-east-1 + SOURCE_DIR: 'docs/build/html/' DEST_DIR: 'latest/' # optional: defaults to entire repository - name: Create Documentation history folder diff --git a/docs/source/_templates/navigation_header.html b/docs/source/_templates/navigation_header.html index d2dc4f70d..3bbb6efb0 100644 --- a/docs/source/_templates/navigation_header.html +++ b/docs/source/_templates/navigation_header.html @@ -8,35 +8,35 @@ diff --git a/docs/source/conf.py b/docs/source/conf.py index a83a34f4d..aafab849e 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -143,7 +143,7 @@ "text": "AequilibraE", "image_light": "_static/large_icon.png", "image_dark": "_static/large_icon.png", - "link": "https://www.aequilibrae.com/dev/home.html", + "link": "https://www.aequilibrae.com/latest/home.html", }, } diff --git a/docs/source/index.rst b/docs/source/index.rst index 86bb9ec0c..8b5d9249b 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -47,7 +47,7 @@ Python Reference guide to AequilibraE's API. .. grid-item-card:: :material-outlined:`person;1.5em` Not a programmer? - :link: https://www.aequilibrae.com/dev/qgis/index.html + :link: https://www.aequilibrae.com/latest/qgis/index.html :text-align: center Take me to the GUI! diff --git a/docs/source/modeling_with_aequilibrae/index.rst b/docs/source/modeling_with_aequilibrae/index.rst index c7c9272f2..fa0e29071 100644 --- a/docs/source/modeling_with_aequilibrae/index.rst +++ b/docs/source/modeling_with_aequilibrae/index.rst @@ -7,7 +7,7 @@ other open-source packages in the Python (NumPy, really) ecosystem. AequilibraE has also a fully features interface available as a plugin for the open source software QGIS, which is separately maintained and discussed in -detail its `documentation `_. +detail its `documentation `_. Contributions are welcome to the existing modules and/or in the form of new modules. diff --git a/docs/source/useful_information/development/softwaredevelopment.rst b/docs/source/useful_information/development/softwaredevelopment.rst index 351dce6f4..7dce42170 100644 --- a/docs/source/useful_information/development/softwaredevelopment.rst +++ b/docs/source/useful_information/development/softwaredevelopment.rst @@ -72,7 +72,7 @@ Style ~~~~~ * Python code should follow (mostly) the `pycodestyle style guide `_ -* Python docstrings should follow the `reStructuredText Docstring Format `_ +* Python docstrings should follow the `reStructuredText Docstring Format `_ * We are big fans of auto-code formatting. For that, we use `ruff `_ and `Black `_. * Negating some of what we have said so far, we use maximum line length of 120 characters diff --git a/docs/source/useful_information/version_history.rst b/docs/source/useful_information/version_history.rst index 4ac3a6801..bd2e53405 100644 --- a/docs/source/useful_information/version_history.rst +++ b/docs/source/useful_information/version_history.rst @@ -188,7 +188,7 @@ In the meantime, you can find the documentation for all versions since 0.5.3. .. grid-item:: .. grid-item-card:: Upcoming version - :link: https://aequilibrae.com/dev/python/index.html + :link: https://aequilibrae.com/latest/python/index.html :link-type: url :text-align: center