Skip to content

Commit

Permalink
feat: add explicit stdin flag
Browse files Browse the repository at this point in the history
  • Loading branch information
mikel-jason committed May 4, 2023
1 parent 3db11dd commit de1901b
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions cmd/helm-clean-values/simple.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,21 @@ var simpleCmd = &cli.Command{
Name: "simple",
Usage: "detect unused helm values by comparing with the chart's default values",
Flags: []cli.Flag{
&cli.BoolFlag{
Name: "stdin",
Usage: "read input values from STDIN",
},
&cli.StringFlag{
Name: "chart",
Usage: "helm prompt to get the chart",
},
},
Before: func(cCtx *cli.Context) error {
if !cCtx.Bool("stdin") {
return fmt.Errorf("no input values provided")
}
return nil
},
Action: func(cCtx *cli.Context) (err error) {

inputProvider := stdin.ValuesProvider{}
Expand Down

0 comments on commit de1901b

Please sign in to comment.