Skip to content

Commit

Permalink
Unified option format
Browse files Browse the repository at this point in the history
Signed-off-by: cleverhu <shouping.hu@daocloud.io>
  • Loading branch information
cleverhu committed Nov 11, 2022
1 parent 41b1ebe commit 600cf10
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 14 deletions.
10 changes: 5 additions & 5 deletions cmd/argocd/commands/login.go
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,11 @@ argocd login cd.argoproj.io --core`,
fmt.Printf("Context '%s' updated\n", ctxName)
},
}
command.Flags().StringVar(&ctxName, "name", "", "name to use for the context")
command.Flags().StringVar(&username, "username", "", "the username of an account to authenticate")
command.Flags().StringVar(&password, "password", "", "the password of an account to authenticate")
command.Flags().BoolVar(&sso, "sso", false, "perform SSO login")
command.Flags().IntVar(&ssoPort, "sso-port", DefaultSSOLocalPort, "port to run local OAuth2 login application")
command.Flags().StringVar(&ctxName, "name", "", "Name to use for the context")
command.Flags().StringVar(&username, "username", "", "The username of an account to authenticate")
command.Flags().StringVar(&password, "password", "", "The password of an account to authenticate")
command.Flags().BoolVar(&sso, "sso", false, "Perform SSO login")
command.Flags().IntVar(&ssoPort, "sso-port", DefaultSSOLocalPort, "Port to run local OAuth2 login application")
command.Flags().
BoolVar(&skipTestTLS, "skip-test-tls", false, "Skip testing whether the server is configured with TLS (this can help when the command hangs for no apparent reason)")
return command
Expand Down
4 changes: 2 additions & 2 deletions cmd/argocd/commands/relogin.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ func NewReloginCommand(globalClientOpts *argocdclient.ClientOptions) *cobra.Comm
fmt.Printf("Context '%s' updated\n", localCfg.CurrentContext)
},
}
command.Flags().StringVar(&password, "password", "", "the password of an account to authenticate")
command.Flags().IntVar(&ssoPort, "sso-port", DefaultSSOLocalPort, "port to run local OAuth2 login application")
command.Flags().StringVar(&password, "password", "", "The password of an account to authenticate")
command.Flags().IntVar(&ssoPort, "sso-port", DefaultSSOLocalPort, "Port to run local OAuth2 login application")
return command
}
10 changes: 5 additions & 5 deletions docs/user-guide/commands/argocd_login.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ argocd login cd.argoproj.io --core

```
-h, --help help for login
--name string name to use for the context
--password string the password of an account to authenticate
--name string Name to use for the context
--password string The password of an account to authenticate
--skip-test-tls Skip testing whether the server is configured with TLS (this can help when the command hangs for no apparent reason)
--sso perform SSO login
--sso-port int port to run local OAuth2 login application (default 8085)
--username string the username of an account to authenticate
--sso Perform SSO login
--sso-port int Port to run local OAuth2 login application (default 8085)
--username string The username of an account to authenticate
```

### Options inherited from parent commands
Expand Down
4 changes: 2 additions & 2 deletions docs/user-guide/commands/argocd_relogin.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ argocd relogin [flags]

```
-h, --help help for relogin
--password string the password of an account to authenticate
--sso-port int port to run local OAuth2 login application (default 8085)
--password string The password of an account to authenticate
--sso-port int Port to run local OAuth2 login application (default 8085)
```

### Options inherited from parent commands
Expand Down

0 comments on commit 600cf10

Please sign in to comment.