PSA: Use a project for building your docs

You could submit coverage from the doc worker too.

But wouldn’t I miss Pkg.test coverage then? Is there a way to have both?

EDIT eg as an example, think of the test setup of PGFPlotsX.

I am not exactly sure how coverage works, but since basically all packages submit a report from each worker I assume the coverage is computed based on all of them, and an additional report from the doc worker should work just fine.

In the case of that example I assume you shouldn’t have to do anything; tests and doc-building are run in the same Travis session so the coverage files should not be removed and one submission should include all of them. The problem is probably just that the coverage flag is not sent to the new process, see pass --code-coverage to doc build process by fredrikekre · Pull Request #144 · KristofferC/PGFPlotsX.jl · GitHub.

I have a follow up clarification question, because as @Tamas_Papp expected, my doc building process is failing whenever I have

    ```@example
    using MyPackage
    ...
    ```

in my markdown documentation with Documenter.jl. It says Package MyPackage not found in current path.

So the three lines

should be added to what file exactly? Does the export line get placed in my module, and the last two lines get run in the command line?

Quite a bit changed since that comment. For current best practices, I recommend following what

https://github.com/JuliaDocs/Documenter.jl

does.

2 Likes