Skip to content

Commit f33099d

Browse files
authored
Update index.md
1 parent 2d94533 commit f33099d

File tree

1 file changed

+29
-34
lines changed

1 file changed

+29
-34
lines changed

docs/src/index.md

Lines changed: 29 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -6,64 +6,59 @@ From this page, you can find a list of tutorials to solve optimal control proble
66

77
## Reproducibility
88

9+
```@setup main
10+
using Pkg
11+
using InteractiveUtils
12+
using Markdown
13+
14+
# Download links for the benchmark environment
15+
function _downloads_toml(DIR)
16+
link_manifest = joinpath("assets", DIR, "Manifest.toml")
17+
link_project = joinpath("assets", DIR, "Project.toml")
18+
return Markdown.parse("""
19+
You can download the exact environment used to build this documentation:
20+
- 📦 [Project.toml]($link_project) - Package dependencies
21+
- 📋 [Manifest.toml]($link_manifest) - Complete dependency tree with versions
22+
""")
23+
end
24+
```
25+
26+
```@example main
27+
_downloads_toml(".") # hide
28+
```
29+
930
```@raw html
10-
<details><summary>The documentation of this package was built using these direct dependencies,</summary>
31+
<details style="margin-bottom: 0.5em; margin-top: 1em;"><summary>ℹ️ Version info</summary>
1132
```
1233

13-
```@example
14-
using Pkg # hide
15-
Pkg.status() # hide
34+
```@example main
35+
versioninfo() # hide
1636
```
1737

1838
```@raw html
1939
</details>
2040
```
2141

2242
```@raw html
23-
<details><summary>and using this machine and Julia version.</summary>
43+
<details style="margin-bottom: 0.5em;"><summary>📦 Package status</summary>
2444
```
2545

26-
```@example
27-
using InteractiveUtils # hide
28-
versioninfo() # hide
46+
```@example main
47+
Pkg.status() # hide
2948
```
3049

3150
```@raw html
3251
</details>
3352
```
3453

3554
```@raw html
36-
<details><summary>A more complete overview of all dependencies and their versions is also provided.</summary>
55+
<details style="margin-bottom: 0.5em;"><summary>📚 Complete manifest</summary>
3756
```
3857

39-
```@example
40-
using Pkg # hide
58+
```@example main
4159
Pkg.status(; mode = PKGMODE_MANIFEST) # hide
4260
```
4361

4462
```@raw html
4563
</details>
4664
```
47-
48-
```@eval
49-
using TOML
50-
using Markdown
51-
version = TOML.parse(read("../../Project.toml", String))["version"]
52-
name = TOML.parse(read("../../Project.toml", String))["name"]
53-
link_manifest = "https://github.com/control-toolbox/" *
54-
name *
55-
".jl/tree/gh-pages/v" *
56-
version *
57-
"/assets/Manifest.toml"
58-
link_project = "https://github.com/control-toolbox/" *
59-
name *
60-
".jl/tree/gh-pages/v" *
61-
version *
62-
"/assets/Project.toml"
63-
Markdown.parse("""You can also download the
64-
[manifest]($link_manifest)
65-
file and the
66-
[project]($link_project)
67-
file.
68-
""")
69-
```

0 commit comments

Comments
 (0)