Skip to content

Commit dbbd83f

Browse files
authored
Merge pull request #1430 from crlf0710/patch-1
Add "rustup doc --reference"
2 parents 5c494e8 + b69c6a0 commit dbbd83f

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/rustup-cli/rustup_mode.rs

+8-1
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,12 @@ pub fn cli() -> App<'static, 'static> {
370370
.long("std")
371371
.help("Standard library API documentation"),
372372
)
373-
.group(ArgGroup::with_name("page").args(&["book", "std"])),
373+
.arg(
374+
Arg::with_name("reference")
375+
.long("reference")
376+
.help("The Rust Reference"),
377+
)
378+
.group(ArgGroup::with_name("page").args(&["book", "std", "reference"])),
374379
);
375380

376381
if cfg!(not(target_os = "windows")) {
@@ -918,6 +923,8 @@ fn doc(cfg: &Cfg, m: &ArgMatches) -> Result<()> {
918923
"book/index.html"
919924
} else if m.is_present("std") {
920925
"std/index.html"
926+
} else if m.is_present("reference") {
927+
"reference/index.html"
921928
} else {
922929
"index.html"
923930
};

0 commit comments

Comments
 (0)