Skip to content

Commit

Permalink
Merge branch 'main' into refactor_allocation_with_metagraph
Browse files Browse the repository at this point in the history
  • Loading branch information
SouthEndMusic committed Nov 21, 2023
2 parents 0e76f9c + 8d6de22 commit fd45fbe
Show file tree
Hide file tree
Showing 9 changed files with 11,390 additions and 7,624 deletions.
8 changes: 4 additions & 4 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
"source.fixAll.ruff": true,
"source.organizeImports.ruff": true
},
"python.analysis.diagnosticSeverityOverrides": {
"reportMissingImports": "none"
},
"[python]": {
"editor.defaultFormatter": "charliermarsh.ruff",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll": true
}
}
},
"python.analysis.extraPaths": [
".pixi/env/Library/python"
]
}
1 change: 1 addition & 0 deletions docs/_quarto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ website:
- contribute/index.qmd
- contribute/core.qmd
- contribute/python.qmd
- contribute/qgis.qmd
- contribute/addnode.qmd
- contribute/release.qmd

Expand Down
2 changes: 1 addition & 1 deletion docs/contribute/index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ title: "Contributing"

Ribasim welcomes contributions.

There is developer documentation for the [Julia core](core.qmd) and [Python tooling](python.qmd).
There is developer documentation for the [Julia core](core.qmd), [Python tooling](python.qmd), and the [QGIS plugin](qgis.qmd).
A guide on how to add a new node type to both is written in [adding node types](addnode.qmd).
[Release process](release.qmd) describes the steps to follow when creating a new Ribasim release.
34 changes: 34 additions & 0 deletions docs/contribute/qgis.qmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
title: "QGIS plugin development"
---

# Set up the developer environment

First set up pixi as described in the [Python tooling](python.qmd) page.

QGIS is installed with Pixi when running `pixi run install`.
To further set up the development environment, you must add the plugins to QGIS.
The simplest way to do this is by running `pixi run install-qgis-plugins`.
It grabs the latest version of the iMOD QGIS plugin and it makes a symlink to the ribasim_qgis folder so that QGIS can find it.

:::{.callout-note}
On Windows you need to have Developer mode enabled.
Otherwise you will not have enough access rights to create symlinks.
For more info, see this [Windows blog](https://blogs.windows.com/windowsdeveloper/2016/12/02/symlinks-windows-10/).
:::

# Running QGIS

In order to run QGIS with the plugins, simply call `pixi run qgis`.
You will find the Ribasim and iMOD plugins in the tool bars.

:::{.callout-note}
On Windows, running QGIS from the start menu will disable Python, and thus the plugins.
QGIS needs some more paths during the startup and the Pixi environment provides those.
:::

# Running tests

To run the QGIS plugin tests in the application environment of QGIS, it is best to make use of the Docker environment provided in this repository. Make sure that docker is installed and available in your path.

Then simply call `pixi run test-ribasim-qgis`.
Loading

0 comments on commit fd45fbe

Please sign in to comment.