launchdarkly/rust-server-sdk

Generate some docs from the code

Closed this issue · 1 comments

Is your feature request related to a problem? Please describe.

On the road to releasing this to the public it's useful if maintainers are able to check the docs generated from the code easily.
This is easiest if they get published somewhere automatically.

Describe the solution you'd like

You can host Rust docs on Netlify for free!
This is how to do it:

Place a rust-toolchain file in the root of the repo (generally a best practice):

[toolchain]
channel = "1.50.0"

Place this netlify.toml file in the root of the repository:

[build]
command = "cargo doc --no-deps"
publish = "target/doc"

Login on app.netlify.com and create a new site based on this repository.

It's done.

From that point on, Netlify will generate docs for the code on the main branch and all pull requests.
You can choose the subdomain on .netlify.app or setup a custom domain.

Describe alternatives you've considered
CircleCI might also be building docs, but they're pretty hard to read there.

Additional context

Let me know if you are struggling with anything around the Netlify setup.
If you'd like to limit access on the site i can also help you install a single-sign-on based site protection using Google or GitHub.

Now that we are publishing releases to crates.io, you can view the latest generated documentation at https://docs.rs/launchdarkly-server-sdk