diff --git a/.github/workflows/sphinx.yml b/.github/workflows/sphinx.yml index b658e23..3de8de3 100644 --- a/.github/workflows/sphinx.yml +++ b/.github/workflows/sphinx.yml @@ -12,32 +12,46 @@ on: jobs: build: - # Linux version requirements + # Specify an OS for the runner runs-on: ubuntu-latest + + #Define steps steps: - # Checkout and build the docs with sphinx - - uses: actions/checkout@v2 - - name: Set up Python 3.10 - uses: actions/setup-python@v2 - with: - python-version: "3.10" + # Firstly, checkout repo + - name: Checkout repository + uses: actions/checkout@v4 + # Set up Python env + - name: Setup Python + uses: actions/setup-python@v5 + with: + python-version: 3.11 + # Install dependencies + - name: Install Python dependencies + run: | + python3 -m pip install --upgrade pip + pip3 install poetry + poetry install + + - name: Build documentation + run: | + mkdir gh-pages + touch gh-pages/.nojekyll + pushd docs/source/ + poetry run sphinx-build -b html . _build + popd + cp -r docs/source/_build/* gh-pages/ - - name: Build HTML - uses: ammaraskar/sphinx-action@master - with: - docs-folder: "docs/" - # pre-build-command: "mkdir /tmp/sphinx-log" - - name: Upload artifacts - uses: actions/upload-artifact@v1 - with: - name: html-docs - path: docs/build/html/ - # Deploys to the gh-pages branch if the commit was made to main, the - # gh-pages then takes over serving the html - - name: Deploy - uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: docs/build/html \ No newline at end of file + - name: Upload artifacts + uses: actions/upload-artifact@v4 + with: + name: html-docs + path: gh-pages + # Deploys to the gh-pages branch if the commit was made to main, the + # gh-pages then takes over serving the html + - name: Deploy documentation + if: ${{ github.event_name == 'push' }} + uses: JamesIves/github-pages-deploy-action@4.1.4 + with: + branch: gh-pages + folder: gh-pages \ No newline at end of file diff --git a/README.md b/README.md index 868f0a1..fda467b 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ Now a repository under cedadev group! Padocc (Pipeline to Aggregate Data for Optimal Cloud Capabilities) is a Data Aggregation pipeline for creating Kerchunk (or alternative) files to represent various datasets in different original formats. Currently the Pipeline supports writing JSON/Parquet Kerchunk files for input NetCDF/HDF files. Further developments will allow GeoTiff, GRIB and possibly MetOffice (.pp) files to be represented, as well as using the Pangeo [Rechunker](https://rechunker.readthedocs.io/en/latest/) tool to create Zarr stores for Kerchunk-incompatible datasets. -[Example Notebooks at this link](https://mybinder.org/v2/gh/cedadev/kerchunk-builder.git/main?filepath=showcase/notebooks) +[Example Notebooks at this link](https://mybinder.org/v2/gh/cedadev/padocc.git/main?filepath=showcase/notebooks) [Documentation hosted at this link](https://cedadev.github.io/kerchunk-builder/)