From: QuietMisdreavus Date: Fri, 16 Mar 2018 18:38:06 +0000 (-0500) Subject: talk about --crate-version X-Git-Url: https://git.lizzy.rs/?a=commitdiff_plain;h=f9d38451382017a6cd053e25011e4c096d545d17;p=rust.git talk about --crate-version --- diff --git a/src/doc/rustdoc/src/unstable-features.md b/src/doc/rustdoc/src/unstable-features.md index 9cb5760ec37..867e4585d9c 100644 --- a/src/doc/rustdoc/src/unstable-features.md +++ b/src/doc/rustdoc/src/unstable-features.md @@ -254,3 +254,15 @@ If both `--playground-url` and `--markdown-playground-url` are present when rend Markdown file, the URL given to `--markdown-playground-url` will take precedence. If both `--playground-url` and `#![doc(html_playground_url = "url")]` are present when rendering crate docs, the attribute will take precedence. + +### `--crate-version`: control the crate version + +Using this flag looks like this: + +```bash +$ rustdoc src/lib.rs -Z unstable-options --crate-version 1.3.37 +``` + +When `rustdoc` receives this flag, it will print an extra "Version (version)" into the sidebar of +the crate root's docs. You can use this flag to differentiate between different versions of your +library's documentation.