diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 622cc739..a07f5bed 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -18,7 +18,7 @@ enough information so someone can reproduce your tests. - [ ] My code follows the style guidelines of this project - [ ] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas -- [ ] I have made corresponding changes to the documentation +- [ ] I have made corresponding changes to the documentation (e.g. add new modules to docs/docstrings/) - [ ] My changes generate no new warnings - [ ] Any dependent changes have been merged and published in downstream modules - [ ] New check tests, if applicable, are included diff --git a/.github/workflows/docs_build.yaml b/.github/workflows/docs_build.yaml new file mode 100644 index 00000000..3b0f1ed1 --- /dev/null +++ b/.github/workflows/docs_build.yaml @@ -0,0 +1,34 @@ +name: "Build docs" + +# This workflow builds the docs to catch us when modules are moved/deleted +# and the auto-generated docstrings can't build anymore. This does not catch +# us when new modules are added. + +# Run these these whenever ... +on: + pull_request: # ... a PR is opened / updated + merge_group: # ... the PR is added to the merge queue + +# cancel running jobs if theres a newer push +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v5 + + - name: Setup Python 3.11 + uses: actions/setup-python@v5 + with: + python-version: '3.11' + + - name: Install mkdocs + run: pip install mkdocs-material mkdocstrings[python] + + - name: Build docs + run: mkdocs build diff --git a/docs/docstrings/initialization/grid_sizer.md b/docs/docstrings/initialization/grid_sizer.md new file mode 100644 index 00000000..eedf0e21 --- /dev/null +++ b/docs/docstrings/initialization/grid_sizer.md @@ -0,0 +1,3 @@ +# grid_sizer + +::: initialization.grid_sizer diff --git a/docs/docstrings/initialization/sizer.md b/docs/docstrings/initialization/sizer.md deleted file mode 100644 index b3dc329a..00000000 --- a/docs/docstrings/initialization/sizer.md +++ /dev/null @@ -1,3 +0,0 @@ -# sizer - -::: initialization.sizer diff --git a/docs/docstrings/initialization/subtile_grid_sizer.md b/docs/docstrings/initialization/subtile_grid_sizer.md new file mode 100644 index 00000000..8219fa92 --- /dev/null +++ b/docs/docstrings/initialization/subtile_grid_sizer.md @@ -0,0 +1,3 @@ +# subtile_grid_sizer + +::: initialization.subtile_grid_sizer diff --git a/docs/docstrings/quantity/state.md b/docs/docstrings/quantity/state.md new file mode 100644 index 00000000..6b33e884 --- /dev/null +++ b/docs/docstrings/quantity/state.md @@ -0,0 +1,3 @@ +# state + +::: quantity.state diff --git a/docs/docstrings/top/global_config.md b/docs/docstrings/top/global_config.md deleted file mode 100644 index f3c2067b..00000000 --- a/docs/docstrings/top/global_config.md +++ /dev/null @@ -1,3 +0,0 @@ -# global_config - -::: global_config diff --git a/mkdocs.yml b/mkdocs.yml index 7e830d65..1ca8682c 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -26,7 +26,6 @@ nav: - "constants": docstrings/top/constants.md - "exceptions": docstrings/top/exceptions.md - "filesystem": docstrings/top/filesystem.md - - "global_config": docstrings/top/global_config.md - "io": docstrings/top/io.md - "logging": docstrings/top/logging.md - "namelist": docstrings/top/namelist.md @@ -77,7 +76,8 @@ nav: - "updater": docstrings/halo/updater.md - initialization: - "allocator": docstrings/initialization/allocator.md - - "sizer": docstrings/initialization/sizer.md + - "grid_sizer": docstrings/initialization/grid_sizer.md + - "subtile_grid_sizer": docstrings/initialization/subtile_grid_sizer.md - monitor: - "convert": docstrings/monitor/convert.md - "netcdf_monitor": docstrings/monitor/netcdf_monitor.md @@ -95,6 +95,7 @@ nav: - "field_bundle": docstrings/quantity/field_bundle.md - "metadata": docstrings/quantity/metadata.md - "quantity": docstrings/quantity/quantity.md + - "state": docstrings/quantity/state.md - restart: - "_legacy_restart": docstrings/restart/_legacy_restart.md - "_properties": docstrings/restart/_properties.md