Commit aa432dfc authored by Matt Butcher's avatar Matt Butcher

fix(helm): print err if no repositories to update

This prints an error if 'helm update' finds no repositories to update.
parent 5e1ef0ce
package main package main
import ( import (
"errors"
"fmt" "fmt"
"io" "io"
"io/ioutil" "io/ioutil"
...@@ -36,6 +37,10 @@ func runUpdate(cmd *cobra.Command, args []string) error { ...@@ -36,6 +37,10 @@ func runUpdate(cmd *cobra.Command, args []string) error {
return err return err
} }
if len(f.Repositories) == 0 {
return errors.New("no repositories found. You must add one before updating")
}
updateCharts(f.Repositories, verboseUpdate) updateCharts(f.Repositories, verboseUpdate)
return nil return nil
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment