-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9a238c5
commit 23ec2d2
Showing
96 changed files
with
7,025 additions
and
28,523 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
/.quarto/ | ||
/_site/ | ||
/site_libs/ | ||
python/reference/ | ||
python/data/ | ||
*.html | ||
/Manifest.toml | ||
objects.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +0,0 @@ | ||
46045333 | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
[deps] | ||
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4" | ||
DocumenterMarkdown = "997ab1e6-3595-5248-9280-8efb232c3433" | ||
InteractiveUtils = "b77e0a4c-d291-57a0-90e8-8db25a27a240" | ||
JSON3 = "0f8b85d8-7281-11e9-16c2-39a750bddbf1" | ||
OrderedCollections = "bac558e1-5e72-5ebc-8fee-abe8a469f55d" | ||
|
||
[compat] | ||
JSON3 = "1.12" | ||
julia = "1.9" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
title: Include Code Files | ||
author: Bruno Beaufils | ||
version: 1.0.0 | ||
quarto-required: ">=1.2" | ||
contributes: | ||
filters: | ||
- include-code-files.lua |
62 changes: 62 additions & 0 deletions
62
_extensions/quarto-ext/include-code-files/include-code-files.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
--- include-code-files.lua – filter to include code from source files | ||
--- | ||
--- Copyright: © 2020 Bruno BEAUFILS | ||
--- License: MIT – see LICENSE file for details | ||
|
||
--- Dedent a line | ||
local function dedent (line, n) | ||
return line:sub(1,n):gsub(" ","") .. line:sub(n+1) | ||
end | ||
|
||
--- Filter function for code blocks | ||
local function transclude (cb) | ||
if cb.attributes.include then | ||
local content = "" | ||
local fh = io.open(cb.attributes.include) | ||
if not fh then | ||
io.stderr:write("Cannot open file " .. cb.attributes.include .. " | Skipping includes\n") | ||
else | ||
local number = 1 | ||
local start = 1 | ||
|
||
-- change hyphenated attributes to PascalCase | ||
for i,pascal in pairs({"startLine", "endLine"}) | ||
do | ||
local hyphen = pascal:gsub("%u", "-%0"):lower() | ||
if cb.attributes[hyphen] then | ||
cb.attributes[pascal] = cb.attributes[hyphen] | ||
cb.attributes[hyphen] = nil | ||
end | ||
end | ||
|
||
if cb.attributes.startLine then | ||
cb.attributes.startFrom = cb.attributes.startLine | ||
start = tonumber(cb.attributes.startLine) | ||
end | ||
for line in fh:lines ("L") | ||
do | ||
if cb.attributes.dedent then | ||
line = dedent(line, cb.attributes.dedent) | ||
end | ||
if number >= start then | ||
if not cb.attributes.endLine or number <= tonumber(cb.attributes.endLine) then | ||
content = content .. line | ||
end | ||
end | ||
number = number + 1 | ||
end | ||
fh:close() | ||
end | ||
-- remove key-value pair for used keys | ||
cb.attributes.include = nil | ||
cb.attributes.startLine = nil | ||
cb.attributes.endLine = nil | ||
cb.attributes.dedent = nil | ||
-- return final code block | ||
return pandoc.CodeBlock(content, cb.attr) | ||
end | ||
end | ||
|
||
return { | ||
{ CodeBlock = transclude } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
project: | ||
type: website | ||
resources: | ||
- schema/*.schema.json | ||
|
||
website: | ||
title: "Ribasim" | ||
page-navigation: true | ||
navbar: | ||
logo: https://user-images.githubusercontent.com/4471859/224825908-bee7e044-bc6b-4561-8b08-5d330cce3ed5.png | ||
left: | ||
- text: "Julia core" | ||
file: core/index.qmd | ||
- text: "Python tooling" | ||
file: python/index.qmd | ||
- text: "QGIS plugin" | ||
file: qgis/index.qmd | ||
- text: "Coupled models" | ||
file: couple/index.qmd | ||
- text: "Contributing" | ||
file: contribute/index.qmd | ||
right: | ||
- icon: github | ||
href: https://github.com/Deltares/Ribasim | ||
aria-label: GitHub | ||
|
||
sidebar: | ||
- title: "Julia core" | ||
contents: | ||
- core/index.qmd | ||
- core/usage.qmd | ||
- core/equations.qmd | ||
- core/allocation.qmd | ||
- core/numerics.qmd | ||
- build/index.md | ||
- title: "Python tooling" | ||
contents: | ||
- python/index.qmd | ||
- python/examples.ipynb | ||
- python/reference/index.qmd | ||
- title: "Coupled models" | ||
contents: | ||
- couple/index.qmd | ||
- couple/modflow.qmd | ||
- couple/modflow-demo.qmd | ||
- title: "Contributing" | ||
contents: | ||
- contribute/index.qmd | ||
- contribute/core.qmd | ||
- contribute/python.qmd | ||
- contribute/addnode.qmd | ||
- contribute/release.qmd | ||
|
||
format: | ||
html: | ||
theme: cosmo | ||
css: assets/styles.css | ||
toc: true | ||
|
||
bibliography: references.bib | ||
number-sections: true | ||
|
||
quartodoc: | ||
style: pkgdown | ||
dir: python/reference | ||
title: API Reference | ||
package: ribasim | ||
sections: | ||
- title: Model | ||
desc: The Model class represents an entire Ribasim model. | ||
contents: | ||
- Model | ||
- title: Network | ||
desc: The Node and Edge database layers define the network layout. | ||
contents: | ||
- Node | ||
- Edge | ||
- title: Node types | ||
desc: Available node types to model different situations. | ||
contents: | ||
- Basin | ||
- FractionalFlow | ||
- TabulatedRatingCurve | ||
- Pump | ||
- Outlet | ||
- User | ||
- LevelBoundary | ||
- FlowBoundary | ||
- LinearResistance | ||
- ManningResistance | ||
- Terminal | ||
- DiscreteControl | ||
- PidControl | ||
- title: Utility functions | ||
desc: Collection of utility functions. | ||
contents: | ||
- utils.geometry_from_connectivity | ||
- utils.connectivity_from_geometry |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
div.wy-menu-vertical ul.current li.toctree-l3 a { | ||
font-weight: bold; | ||
} | ||
|
||
a.documenter-source { | ||
float: right; | ||
} | ||
|
||
.documenter-methodtable pre { | ||
margin-left: 0; | ||
margin-right: 0; | ||
margin-top: 0; | ||
padding: 0; | ||
} | ||
|
||
.documenter-methodtable pre.documenter-inline { | ||
display: inline; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
MathJax.Hub.Config({ | ||
"tex2jax": { | ||
inlineMath: [['$','$'], ['\\(','\\)']], | ||
processEscapes: true | ||
} | ||
}); | ||
MathJax.Hub.Config({ | ||
config: ["MMLorHTML.js"], | ||
jax: [ | ||
"input/TeX", | ||
"output/HTML-CSS", | ||
"output/NativeMML" | ||
], | ||
extensions: [ | ||
"MathMenu.js", | ||
"MathZoom.js", | ||
"TeX/AMSmath.js", | ||
"TeX/AMSsymbols.js", | ||
"TeX/autobold.js", | ||
"TeX/autoload-all.js" | ||
] | ||
}); | ||
MathJax.Hub.Config({ | ||
TeX: { equationNumbers: { autoNumber: "AMS" } } | ||
}); |
Oops, something went wrong.