Skip to content

Commit

Permalink
Add shorthand '-s' for --subscription. (#2708)
Browse files Browse the repository at this point in the history
Add shorthand '-s' for `--subscription`.

Co-authored-by: zedy <zedy@wicresoft.com>
  • Loading branch information
zedy-wj and zedy committed Sep 6, 2023
1 parent 9b48d01 commit 1702f10
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion cli/azd/cmd/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,10 @@ func (i *initFlags) Bind(local *pflag.FlagSet, global *internal.GlobalCommandOpt
"b",
"",
"The template branch to initialize from. Must be used with a template argument (--template or -t).")
local.StringVar(
local.StringVarP(
&i.subscription,
"subscription",
"s",
"",
"Name or ID of an Azure subscription to use for the new environment",
)
Expand Down
2 changes: 1 addition & 1 deletion cli/azd/cmd/testdata/TestUsage-azd-init.snap
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Flags
-e, --environment string : The name of the environment to use.
-h, --help : Gets help for init.
-l, --location string : Azure location for the new environment
--subscription string : Name or ID of an Azure subscription to use for the new environment
-s, --subscription string : Name or ID of an Azure subscription to use for the new environment
-t, --template string : The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Global Flags
Expand Down

0 comments on commit 1702f10

Please sign in to comment.