Confusing about -e and CLI use (relates to package precompilation)

What I did:

  • I cloned you repository
  • I run:
julia --project
using Pkg
Pkg.update()

That worked fine. Then I tried to build the documentation with:

include("scripts/build_docu.jl")

This failed because two PNG files were missing, maps.png and asmr.png.

I was able to create these png files using your scripts.

Now, I can successfully build the documentation using the include command above.

It also works without REPL:

ufechner@ufryzen:~/repos/OceanAnalysis.jl$ julia --project -e 'include("scripts/build_docu.jl")'
  Activating project at `~/.julia/environments/v1.11`
  Activating project at `~/repos/OceanAnalysis.jl`
  Activating project at `~/.julia/environments/v1.11`
  Activating project at `~/repos/OceanAnalysis.jl`
[ Info: SetupBuildDirectory: setting up build directory.
[ Info: Doctest: running doctests.
[ Info: ExpandTemplates: expanding markdown templates.
[ Info: CrossReferences: building cross-references.
[ Info: CheckDocument: running document checks.
[ Info: Populate: populating indices.
[ Info: RenderDocument: rendering document.
[ Info: HTMLWriter: rendering HTML pages.
[ Info: Automatic `version="0.1.0"` for inventory from ../Project.toml
┌ Warning: Documenter could not auto-detect the building environment. Skipping deployment.
└ @ Documenter ~/.julia/packages/Documenter/eoWm2/src/deployconfig.jl:93
✓ LiveServer listening on http://localhost:8000/ ...
  (use CTRL+C to shut down)
^C
⋮ shutting down LiveServer… ✓

Can you reproduce my results?

1 Like