bootstrap: show available paths help text for aliased subcommands

Running `./x.py build -h -v` shows a list of available build targets,
but the short alias `./x.py b -h -v` does not. Fix so that the aliases
behave the same as their spelled out counterparts.
This commit is contained in:
Allen Wild 2022-04-10 03:10:04 -04:00
parent f7b4824731
commit e4bbbacb8c

View File

@ -621,9 +621,9 @@ macro_rules! describe {
pub fn get_help(build: &Build, subcommand: &str) -> Option<String> { pub fn get_help(build: &Build, subcommand: &str) -> Option<String> {
let kind = match subcommand { let kind = match subcommand {
"build" => Kind::Build, "build" | "b" => Kind::Build,
"doc" => Kind::Doc, "doc" | "d" => Kind::Doc,
"test" => Kind::Test, "test" | "t" => Kind::Test,
"bench" => Kind::Bench, "bench" => Kind::Bench,
"dist" => Kind::Dist, "dist" => Kind::Dist,
"install" => Kind::Install, "install" => Kind::Install,