I’m trying to follow the Guide to set up a basic documentation. I used pkg> generate
Example in order to generate an example package and then DocumenterTools.generate
as suggested. I then created an empty index.md
file in /docs/src
and ran the automatically generated make.jl
file. I then get the following output:
[ Info: SetupBuildDirectory: setting up build directory.
[ 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.
which is slightly different from what I expected, but no other problems so far.
I then add a function func
with associated docstring exactly as described in the guide.
When I re-run make.jl
, I get
┌ Warning: 1 docstring potentially missing:
│
│ Example.func :: Tuple{Any}
└ @ Documenter.DocChecks ~/.julia/packages/Documenter/msPrq/src/DocChecks.jl:62
which indicates that the function was found but there is no corresponding documentation.
I then add an entry to index.md
. But upon re-running make.jl
, I get
┌ Warning: duplicate docs found for 'func(x)' in `@docs` block in src/index.md:3-5
│ ```@docs
│ func(x)
│ ```
└ @ Documenter.Expanders ~/.julia/packages/Documenter/msPrq/src/Expanders.jl:301
and the build html file has a missing docstring
warning.
Now I don’t understand what this is trying to tell me; as far as I’m aware there is only one docstring for the function in question. I could be missing a step that ensures that the docstring is read correctly.
But how do I set up this example correctly?