Skip to content

Commit

Permalink
EVEREST-837 | Help message missing for some sub-commands (#403)
Browse files Browse the repository at this point in the history
  • Loading branch information
mayankshah1607 authored Jun 14, 2024
1 parent 473a37d commit 01a943d
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 2 deletions.
2 changes: 2 additions & 0 deletions commands/accounts/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ func NewCreateCmd(l *zap.SugaredLogger) *cobra.Command {
cmd := &cobra.Command{
Use: "create",
Example: "everestctl accounts create --username user1 --password $USER_PASS",
Short: "Create a new Everest user account",
Long: "Create a new Everest user account",
Run: func(cmd *cobra.Command, args []string) { //nolint:revive
initCreateViperFlags(cmd)

Expand Down
2 changes: 2 additions & 0 deletions commands/accounts/delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ func NewDeleteCmd(l *zap.SugaredLogger) *cobra.Command {
cmd := &cobra.Command{
Use: "delete",
Example: "everestctl accounts delete --username user1",
Short: "Delete an existing Everest user account",
Long: "Delete an existing Everest user account",
Run: func(cmd *cobra.Command, args []string) { //nolint:revive
initDeleteViperFlags(cmd)

Expand Down
1 change: 1 addition & 0 deletions commands/accounts/initial_admin_password.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ func NewInitialAdminPasswdCommand(l *zap.SugaredLogger) *cobra.Command {
Use: "initial-admin-password",
Example: "everestctl accounts initial-admin-password",
Long: "Get the initial admin password for Everest",
Short: "Get the initial admin password for Everest",
Run: func(cmd *cobra.Command, args []string) { //nolint:revive
viper.BindEnv("kubeconfig") //nolint:errcheck,gosec
viper.BindPFlag("kubeconfig", cmd.Flags().Lookup("kubeconfig")) //nolint:errcheck,gosec
Expand Down
2 changes: 2 additions & 0 deletions commands/accounts/list.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ func NewListCmd(l *zap.SugaredLogger) *cobra.Command {
cmd := &cobra.Command{
Use: "list",
Example: "everestctl accounts list",
Long: "List all Everest user accounts",
Short: "List all Everest user accounts",
Run: func(cmd *cobra.Command, args []string) { //nolint:revive
initListViperFlags(cmd)
o := &accountscli.ListOptions{}
Expand Down
1 change: 1 addition & 0 deletions commands/accounts/reset_jwt_keys.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ func NewResetJWTKeysCommand(l *zap.SugaredLogger) *cobra.Command {
Use: "reset-jwt-keys",
Example: "everestctl accounts reset-jwt-keys",
Long: "Reset the JWT keys used for Everest user authentication",
Short: "Reset the JWT keys used for Everest user authentication",
Run: func(cmd *cobra.Command, args []string) { //nolint:revive
viper.BindEnv("kubeconfig") //nolint:errcheck,gosec
viper.BindPFlag("kubeconfig", cmd.Flags().Lookup("kubeconfig")) //nolint:errcheck,gosec
Expand Down
2 changes: 2 additions & 0 deletions commands/accounts/set_password.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ func NewSetPwCommand(l *zap.SugaredLogger) *cobra.Command {
cmd := &cobra.Command{
Use: "set-password",
Example: "everestctl accounts set-password --username user1 --new-password $USER_PASS",
Long: "Set a new password for an existing Everest user account",
Short: "Set a new password for an existing Everest user account",
Run: func(cmd *cobra.Command, args []string) { //nolint:revive
initSetPwViperFlags(cmd)

Expand Down
2 changes: 1 addition & 1 deletion commands/settings/oidc.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import (
func NewOIDCCmd(l *zap.SugaredLogger) *cobra.Command {
cmd := &cobra.Command{
Use: "oidc",
Long: "Configure OIDC settings",
Long: "Manage settings related to OIDC",
}

cmd.AddCommand(oidc.NewConfigureCommand(l))
Expand Down
4 changes: 3 additions & 1 deletion commands/settings/oidc/configure.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ import (
// NewConfigureCommand returns the command to configure OIDC.
func NewConfigureCommand(l *zap.SugaredLogger) *cobra.Command {
cmd := &cobra.Command{
Use: "configure",
Use: "configure",
Long: "Configure OIDC settings",
Short: "Configure OIDC settings",
Run: func(cmd *cobra.Command, args []string) { //nolint:revive
initOIDCViperFlags(cmd)
c, err := parseOIDCConfig()
Expand Down

0 comments on commit 01a943d

Please sign in to comment.