Hi,
I was wondering what would be the best practice to produce a mdbook that accompanies a crate (or a workspace). Some options:
- A completely separate project. In this case there would have to be a way to specify dependencies for the code snippets in the book. This would be ad-hoc (using
--library-path
on invocation) as there is no way to formally add dependencies to mdbook. - A directory inside the main crate. The problem here is that there is no way, AFAIK, for
cargo test
to callmdbook test
in one of its directories. I could imagine an integration test framework (travis, circle, azure pipelines, ...) calling bothcargo test
andmdbook test
separately. - A similar argument to 2 can be made for workspaces.
Any ideas? Am I forgetting something obivous?
Thanks,