Skip to content

Commit

Permalink
add shorthand of flags
Browse files Browse the repository at this point in the history
  • Loading branch information
childe committed Sep 12, 2024
1 parent 7eaaacc commit d2a369d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion command/cmd/delete-groups.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,5 +62,5 @@ var deleteGroupsCmd = &cobra.Command{
}

func init() {
deleteGroupsCmd.Flags().StringSlice("groups", nil, "group names, separated by comma")
deleteGroupsCmd.Flags().StringSliceP("groups", "g", nil, "group names, separated by comma")
}
2 changes: 1 addition & 1 deletion command/cmd/delete-topics.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ var deleteTopicsCmd = &cobra.Command{
}

func init() {
deleteTopicsCmd.Flags().StringSlice("topics", nil, "topic names, separated by comma")
deleteTopicsCmd.Flags().StringSliceP("topics", "t", nil, "topic names, separated by comma")

rootCmd.AddCommand(deleteTopicsCmd)
}
2 changes: 1 addition & 1 deletion command/cmd/describe-groups.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,5 +63,5 @@ var describeGroupsCmd = &cobra.Command{
}

func init() {
describeGroupsCmd.Flags().String("group", "", "group names")
describeGroupsCmd.Flags().StringP("group", "g", "", "group names")
}

0 comments on commit d2a369d

Please sign in to comment.