Skip to content

Commit

Permalink
fix: double errors (#23)
Browse files Browse the repository at this point in the history
  • Loading branch information
sozercan authored Apr 15, 2023
1 parent 4df7767 commit 9dadc9f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmd/cli/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,15 @@ func InitAndExecute() {
}

if err := RootCmd().Execute(); err != nil {
fmt.Println(err)
os.Exit(1)
}
}

func RootCmd() *cobra.Command {
cmd := &cobra.Command{
Use: "kubectl-ai",
Version: version,
Use: "kubectl-ai",
Version: version,
SilenceUsage: true,
RunE: func(cmd *cobra.Command, args []string) error {
if len(args) == 0 {
return fmt.Errorf("prompt must be provided")
Expand Down

0 comments on commit 9dadc9f

Please sign in to comment.