Skip to content

Customising your docs ​

scaffold seeds your docs pages once, and then they are yours. This page lists which files you edit and how.

What's package-owned here ​

update never rewrites these:

  • tutorials/index.md, the quickstart a new user sees first.

  • Any other page under docs/src/.

  • docs/docs_config.jl, which names your pages for the navigation (see Documentation layout).

  • The README body, outside the badge block and the standard-section markers.

  • CITATION.cff, your citation metadata, which GitHub uses for its "Cite this repository" widget. Update it as you release.

  • docs/src/extensions/*.md, one page per extension (see below).

See Infrastructure and template sync for the full split.

Making it your own ​

  • Replace the quickstart in tutorials/index.md with real install steps and a runnable first example.

  • Add a page in the folder of its group (tutorials, how-to, explanation, reference), then list it in docs/docs_config.jl. update writes it into docs/pages.jl.

  • Pages appear in the order you list them. The kit fixes the order of the groups.

This site is itself a scaffolded adopter, so its pages are a worked example.

Documenting extensions ​

Each [extensions] entry gets a page under docs/src/extensions/ and a nav entry labelled with its trigger package, such as Plots. The Extensions group sits under Reference. Write what the extension adds and what a reader must load to get it.

The seeded API block is inert. To turn it on, add the trigger package to docs/Project.toml and replace the outer block with the one inside it.

For one docs/src/extensions.md page with a section per extension, set const EXTENSIONS_SINGLE_PAGE = true in docs/docs_config.jl.

How extension pages are built

The API block is shown as code rather than run because an extension module exists only once its trigger packages load. A live @autodocs block would fail the build when the docs environment lacks them. The build loads every trigger package the docs environment has and adds the extension modules to Documenter. A missing trigger is skipped with a warning. update rewrites the Extensions nav from the current [extensions] on every sync, but only scaffold seeds the pages. The build drops a nav entry whose page is missing, and drops the group when it is empty. EXTENSIONS_SINGLE_PAGE defaults to false.

Tutorials with their own environment ​

Tutorials use the shared docs/ environment. Give a tutorial its own environment only when its dependencies cannot resolve alongside the others. Map it in TUTORIAL_ENVIRONMENTS in docs/docs_config.jl, keyed by its path relative to the tutorials folder:

julia
const TUTORIAL_ENVIRONMENTS = Pair{String, String}[
    "my-tutorial.jl" => "environments/my-tutorial",
]

Create docs/environments/my-tutorial/Project.toml with the tutorial's dependencies, Literate, and a [sources] entry pointing at the package root:

toml
[deps]
Literate = "98b081ad-f1c9-55d3-8b20-4c87d4299306"

[sources]
MyPackage = {path = "../../.."}

The build instantiates it before the tutorial runs. A missing directory, a missing Literate or a failed resolve fails the build with a message naming the environment.

Details

The path is relative to docs/ unless absolute. Use one directory per tutorial under environments/, so tutorials can hold conflicting versions. Each resolves on its own, outside the root [workspace]. The managed Dependabot config watches docs/environments/*, so an environment elsewhere still builds but never gets dependency updates. The kit never writes this environment. The build does not fall back to the shared environment, which would show a fast-build stub in place of the tutorial. Each extra environment costs a resolve and precompile on every build.

Running heavy tutorials in parallel ​

Heavy tutorials run one at a time. Set HEAVY_TUTORIAL_WORKERS in docs/docs_config.jl to run more at once. It defaults to 1. Raise it when the docs build nears a CI time limit, and watch memory above 2 on a standard runner.

Memory, threads and output

Each heavy tutorial runs in its own subprocess with no shared state, so order does not matter. Memory is the limit. A Turing subprocess can hold several GB, and running out kills the build. Each worker gets JULIA_NUM_THREADS ÷ workers threads, at least one, so total thread use matches a serial build. This trades threads within a tutorial, such as chains under MCMCThreads(), for running tutorials side by side. It pays off when there are more tutorials than chains to spread across cores. Each tutorial's output prints as one block, headed by its name, when it finishes. A failure does not stop the others, and every failure is listed at the end.

What stays managed ​

  • docs/make.jl, which calls the kit's build.

  • docs/pages.jl, generated from docs/docs_config.jl.

  • The VitePress theme and components under docs/src/.vitepress/ and docs/src/components/.

  • The API reference pages, generated from docstrings on every build.

  • The README standard sections (Contributing, How to cite, Code of conduct) between the standard-sections markers. Put your own prose outside the markers and citation details in CITATION.cff.

update and template sync revert edits to these files. To own one anyway, add an EPIAWARE_MANAGED_OVERRIDE comment to it and sync keeps it (see Infrastructure and template sync).