Skip to content

Commit

Permalink
Merge branch 'main' into precipitation-planetary
Browse files Browse the repository at this point in the history
  • Loading branch information
barneydobson authored Nov 22, 2024
2 parents 67b6914 + 446fd2b commit 4aad843
Show file tree
Hide file tree
Showing 13 changed files with 2,078 additions and 8 deletions.
1 change: 1 addition & 0 deletions .github/workflows/check-links.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,4 @@ jobs:
with:
use-quiet-mode: 'yes'
use-verbose-mode: 'yes'
config-file: .markdown-link-check.json
44 changes: 42 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,24 @@ permissions:
id-token: write

jobs:
test-docs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
with:
python-version: "3.11"

- name: Install dependencies
run: |
pip install .[doc]
python -c "import pypandoc; pypandoc.download_pandoc()"
- name: Test Docs
run: mkdocs build

test:
uses: ./.github/workflows/ci_template.yml
secrets:
Expand Down Expand Up @@ -73,9 +91,29 @@ jobs:
- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1

paper:
runs-on: ubuntu-latest
needs: publish-PyPI
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Build draft PDF
uses: openjournals/openjournals-draft-action@master
with:
journal: joss
# This should be the path to the paper within your repo.
paper-path: docs/paper/paper.md
- name: Upload
uses: actions/upload-artifact@v4
with:
name: paper
# This is the output path where Pandoc will write the compiled
# PDF. Note, this should be the same directory as the input
# paper.md
path: docs/paper/paper.pdf

publish-docs:
needs: publish-PyPI
needs: paper
runs-on: ubuntu-latest

steps:
Expand All @@ -86,7 +124,9 @@ jobs:
python-version: "3.11"

- name: Install dependencies
run: pip install .[doc]
run: |
pip install .[doc]
python -c "import pypandoc; pypandoc.download_pandoc()"
- name: Deploy Docs
run: mkdocs gh-deploy --force
7 changes: 7 additions & 0 deletions .markdown-link-check.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"ignorePatterns": [
{
"pattern": ".*/paper.pdf"
}
]
}
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ repos:
- id: check-merge-conflict
- id: debug-statements
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.7.2"
rev: "v0.7.4"
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
Expand All @@ -20,7 +20,7 @@ repos:
rev: v0.42.0
hooks:
- id: markdownlint
args: ["--disable", "MD013", "--"]
args: ["--disable", "MD013", "--disable", "MD025", "--"]

- repo: https://github.com/codespell-project/codespell
rev: v2.3.0
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
[![Test and build](https://github.com/ImperialCollegeLondon/SWMManywhere/actions/workflows/ci.yml/badge.svg)](https://github.com/ImperialCollegeLondon/SWMManywhere/actions/workflows/ci.yml)
[![DOI](https://zenodo.org/badge/741903266.svg)](https://zenodo.org/doi/10.5281/zenodo.13837741)
[![codecov](https://codecov.io/gh/ImperialCollegeLondon/SWMManywhere/graph/badge.svg)](https://codecov.io/gh/ImperialCollegeLondon/SWMManywhere)
[![status](https://joss.theoj.org/papers/b9901c3b612b995bf6977377b65f368a/status.svg)](https://joss.theoj.org/papers/b9901c3b612b995bf6977377b65f368a)

<!-- markdown-link-check-enable -->

SWMManywhere is a tool to synthesise urban drainage network models (UDMs) using
Expand Down
4 changes: 3 additions & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ derive a synthetic urban drainage network anywhere in the world.
## Table of contents
<!-- markdownlint-disable MD007 -->
- [Home](index.md)
- [About](./paper/paper.pdf)
- [Quickstart](quickstart.md)
- Guides:
- [Configuration file](config_guide.md)
Expand All @@ -24,4 +25,5 @@ derive a synthetic urban drainage network anywhere in the world.
- [Post processing](reference-post-processing.md)
- [Preprocessing](reference-preprocessing.md)
- [Config](reference-defs.md)
<!--- - [Coverage report](coverage.md)--->
- [Coverage report](https://app.codecov.io/gh/ImperialCollegeLondon/SWMManywhere)
<!--- --->
Loading

0 comments on commit 4aad843

Please sign in to comment.