Skip to content

Commit

Permalink
Formatting and shortern shell flag
Browse files Browse the repository at this point in the history
  • Loading branch information
yangl900 committed May 21, 2019
1 parent b12e411 commit 85bad23
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions main.go
Expand Up @@ -21,7 +21,7 @@ func main() {
flag.StringVar(&tenantID, "tenant", "", "Specify the tenant Id.")
flag.BoolVar(&reset, "reset", false, "Reset the presisted tenant settings.")
flag.BoolVar(&help, "help", false, "Show the help text.")
flag.StringVar(&shellType,"shelltype","","Force to request the specified shell type (bash|pwsh)")
flag.StringVar(&shellType, "shell", "", "Force to request the specified shell (bash|pwsh).")
flag.Parse()

if help {
Expand Down Expand Up @@ -102,11 +102,10 @@ func main() {
return
}

if ((shellType != "pwsh") && (shellType != "bash")) {
if shellType != "pwsh" && shellType != "bash" {
shellType = css.Properties.PreferredShellType
}


t, err := RequestTerminal(tenantID, uri, shellType)
if err != nil || t.SocketURI == "" {
fmt.Println("Failed to connect to cloud shell terminal.", err)
Expand Down

0 comments on commit 85bad23

Please sign in to comment.