Skip to content

Commit

Permalink
fix npe running with no args
Browse files Browse the repository at this point in the history
  • Loading branch information
WillAbides committed Dec 22, 2023
1 parent 1e12498 commit b446303
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cmd/bindown/cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ type rootCmd struct {
}

func (r *rootCmd) BeforeApply(k *kong.Context) error {
if k == nil || k.Selected() == nil {
return nil
}
// set dependency positional to optional for install, wrap, download and extract.
// We do this because we want to allow --all to be equivalent to specifying all
// dependencies but want the help output to indicate that a dependency is required.
Expand Down

0 comments on commit b446303

Please sign in to comment.