Should Documenter be part of Project.toml?

I have a main Project.toml, and a second one in the folder docs.

I removed Documenter from the main Project.toml, but now I cannot build any longer the documentation locally, even though the Project.toml in the docs folder exists. Content:

Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
KiteUtils = "90980105-b163-44e5-ba9f-8b1c83bb0533"

How can I tell Julia to use this nested Project.toml ?

Hi @ufechner7 ,

I use the make.jl approach in my set-up for LuxCat.jl.
Perhaps this approach may assist in your situation?
It’s a bit hard to tell what exactly your problem is without seeing the repo or code - are you at liberty to show it?
Additionally, here is my docs deployment yaml via GitHub Actions if you deploy your docs somewhere: LuxCat.jl/ci.yml at 178a34fb0e169eac6d8669c9f10d8ac028e5c0e2 · TheCedarPrince/LuxCat.jl · GitHub

Let me know if you have additional questions - happy to attempt helping!

~ tcp :deciduous_tree:

1 Like

Thanks for your answer!
You can find my package here: GitHub - ufechner7/KiteUtils.jl: Utilities for kite power system simulations

I think I solved my problem: To create the documentation locally, I had to:

  1. navigate to the docs folder
  2. run julia --project
  3. using Pkg; Pkg.resolve()
  4. include("make.jl")

So the problem is solved, but I guess it should be documented somewhere…

I am also still looking for the optimal Documenter.jl workflow. The only thing I can suggest, which is what I am thinking of using, is to use the Pkg module to automate some of the environment switching in docs/make.jl. By doing this, I can run make.jl and it will do the right thing even if I forget about switching into the docs environment.