File tree Expand file tree Collapse file tree 3 files changed +5
-2
lines changed Expand file tree Collapse file tree 3 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -319,7 +319,7 @@ Some common cargo commands are (see all commands with --list):
319319 build, b Compile the current package
320320 check, c Analyze the current package and report errors, but don't build object files
321321 clean Remove the target directory
322- doc Build this package's and its dependencies' documentation
322+ doc, d Build this package's and its dependencies' documentation
323323 new Create a new cargo package
324324 init Create a new cargo package in an existing directory
325325 run, r Run a binary or example of the local package
Original file line number Diff line number Diff line change @@ -4,6 +4,8 @@ use cargo::ops::{self, DocOptions};
44
55pub fn cli ( ) -> App {
66 subcommand ( "doc" )
7+ // subcommand aliases are handled in aliased_command()
8+ // .alias("d")
79 . about ( "Build a package's documentation" )
810 . arg ( opt ( "quiet" , "No output printed to stdout" ) . short ( "q" ) )
911 . arg ( opt (
Original file line number Diff line number Diff line change @@ -48,9 +48,10 @@ fn main() {
4848
4949/// Table for defining the aliases which come builtin in `Cargo`.
5050/// The contents are structured as: `(alias, aliased_command, description)`.
51- const BUILTIN_ALIASES : [ ( & str , & str , & str ) ; 4 ] = [
51+ const BUILTIN_ALIASES : [ ( & str , & str , & str ) ; 5 ] = [
5252 ( "b" , "build" , "alias: build" ) ,
5353 ( "c" , "check" , "alias: check" ) ,
54+ ( "d" , "doc" , "alias: doc" ) ,
5455 ( "r" , "run" , "alias: run" ) ,
5556 ( "t" , "test" , "alias: test" ) ,
5657] ;
You can’t perform that action at this time.
0 commit comments