From 364de6f785f69dd30674860d8f7d4983e7c46269 Mon Sep 17 00:00:00 2001 From: Andrew Rosemberg Date: Wed, 6 Aug 2025 21:48:36 -0400 Subject: [PATCH 1/9] Update class01.md --- class01/class01.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/class01/class01.md b/class01/class01.md index 37bb6dd..58f9452 100644 --- a/class01/class01.md +++ b/class01/class01.md @@ -2,7 +2,7 @@ **Presenter:** Andrew Rosemberg -**Topic:** Course map; why PDE-constrained optimization; tooling overview; stability & state-space dynamics; Lyapunov; discretization issues +**Topic:** Course map; why PDE-constrained optimization; tooling overview; stability & state-space dynamics; Lyapunov; discretization issues. --- @@ -72,4 +72,4 @@ We have prepared a basic (Pluto) [Linear Algebra Primer](./background_materials/ ### **Optimization**: We will use JuMP for some optimization tasks. If you are new to JuMP, please review the [JuMP Tutorial](https://jump.dev/JuMP.jl/stable/tutorials/getting_started/getting_started_with_JuMP/) to familiarize yourself with its syntax and capabilities. -Test your knowledge with this (Pluto) [Modeling Exercise](./background_materials/optimization_homework.jl). \ No newline at end of file +Test your knowledge with this (Pluto) [Modeling Exercise](./background_materials/optimization_homework.jl). From 7dcf4566be7715bb208718ce620e2012ead92fe2 Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 6 Aug 2025 21:54:09 -0400 Subject: [PATCH 2/9] update --- .github/{workflows => workflows}/documentation.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/{workflows => workflows}/documentation.yml (100%) diff --git a/.github/workflows /documentation.yml b/.github/workflows/documentation.yml similarity index 100% rename from .github/workflows /documentation.yml rename to .github/workflows/documentation.yml From d6a423cc46cccebd1db5455278f59b338d99bd6c Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 6 Aug 2025 21:55:54 -0400 Subject: [PATCH 3/9] path toml --- .github/workflows/documentation.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 7b54308..5094f7f 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -20,7 +20,7 @@ jobs: version: '1' - uses: julia-actions/cache@v2 - name: Install dependencies - run: julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()' + run: julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=joinpath(pwd(),"docs"))); Pkg.instantiate()' - name: Setup symlink run: ln -s ../../class01/class01.md class01.md working-directory: docs/src From 1e756b23c1bbac6576c938e3039d0c22efe7a72f Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 6 Aug 2025 21:57:41 -0400 Subject: [PATCH 4/9] fix error path --- .github/workflows/documentation.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 5094f7f..8b5c9ae 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -20,7 +20,7 @@ jobs: version: '1' - uses: julia-actions/cache@v2 - name: Install dependencies - run: julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=joinpath(pwd(),"docs"))); Pkg.instantiate()' + run: julia --project=docs/ -e 'using Pkg; Pkg.instantiate()' - name: Setup symlink run: ln -s ../../class01/class01.md class01.md working-directory: docs/src From 093cb0b824007a99fbd3d7d518692e049d9f275e Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 6 Aug 2025 22:06:19 -0400 Subject: [PATCH 5/9] test link --- docs/make.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/make.jl b/docs/make.jl index 32d0c6f..bda453f 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -24,7 +24,7 @@ makedocs( ), pages = [ "Home" => "index.md", - "Class 1" => "class01.md", + "Class 1" => "class01/class01.md", ], ) From cd9c79febf418125e0432c926a56accb53498fe2 Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 6 Aug 2025 22:09:18 -0400 Subject: [PATCH 6/9] add assert --- docs/make.jl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/make.jl b/docs/make.jl index bda453f..f9e734f 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -10,6 +10,8 @@ plutos = [ joinpath(repo_dir, "class01", "background_materials", "basics_math.jl"), ] +@assert isfile(repo_dir, "docs", "class01.md") "Expected docs/class01.md to exist." + makedocs( sitename = "LearningToControlClass", format = Documenter.HTML(; @@ -24,7 +26,7 @@ makedocs( ), pages = [ "Home" => "index.md", - "Class 1" => "class01/class01.md", + "Class 1" => "class01.md", ], ) From 67338695ca0883329c9336980abfc83ad1d13be5 Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 6 Aug 2025 22:09:59 -0400 Subject: [PATCH 7/9] fix path assert --- docs/make.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/make.jl b/docs/make.jl index f9e734f..5239040 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -10,7 +10,7 @@ plutos = [ joinpath(repo_dir, "class01", "background_materials", "basics_math.jl"), ] -@assert isfile(repo_dir, "docs", "class01.md") "Expected docs/class01.md to exist." +@assert isfile(repo_dir, "docs", "src", "class01.md") "Expected docs/class01.md to exist." makedocs( sitename = "LearningToControlClass", From ced1cdb2492f339d21399b8485ae138be45b130b Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 6 Aug 2025 22:13:20 -0400 Subject: [PATCH 8/9] create symlink in julia --- docs/make.jl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/make.jl b/docs/make.jl index 5239040..b70a062 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -10,7 +10,9 @@ plutos = [ joinpath(repo_dir, "class01", "background_materials", "basics_math.jl"), ] -@assert isfile(repo_dir, "docs", "src", "class01.md") "Expected docs/class01.md to exist." +symlink(joinpath(repo_dir, "class01", "class01.md"), + joinpath(repo_dir, "docs", "src", "class01.md") +) makedocs( sitename = "LearningToControlClass", From bbd1bdaa52d432161585a3ea34691fefd6b1e94a Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 6 Aug 2025 22:31:23 -0400 Subject: [PATCH 9/9] update generator --- .github/workflows/documentation.yml | 6 +++--- docs/make.jl | 12 ++++++++---- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 8b5c9ae..1396165 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -21,9 +21,9 @@ jobs: - uses: julia-actions/cache@v2 - name: Install dependencies run: julia --project=docs/ -e 'using Pkg; Pkg.instantiate()' - - name: Setup symlink - run: ln -s ../../class01/class01.md class01.md - working-directory: docs/src + # - name: Setup symlink + # run: ln -s ../../class01/class01.md class01.md + # working-directory: docs/src - name: Build and deploy env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/docs/make.jl b/docs/make.jl index b70a062..98cf4e0 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -10,9 +10,11 @@ plutos = [ joinpath(repo_dir, "class01", "background_materials", "basics_math.jl"), ] -symlink(joinpath(repo_dir, "class01", "class01.md"), - joinpath(repo_dir, "docs", "src", "class01.md") -) +if !isdir(build_dir) + symlink(joinpath(repo_dir, "class01"), + joinpath(repo_dir, "docs", "src", "class01") + ) +end makedocs( sitename = "LearningToControlClass", @@ -28,10 +30,12 @@ makedocs( ), pages = [ "Home" => "index.md", - "Class 1" => "class01.md", + "Class 1" => ["class01/class01.md"], ], ) +rm(joinpath(repo_dir, "docs", "src", "class01"), force=true) + s = Pluto.ServerSession(); for pluto in plutos nb = Pluto.SessionActions.open(s, pluto; run_async=false)