|
|
@ -68,7 +68,7 @@ By default, the default directories depend on the Operating System. The defaults
|
|
|
|
| Windows | %TEMP%\helm | %APPDATA%\helm | %APPDATA%\helm |
|
|
|
|
| Windows | %TEMP%\helm | %APPDATA%\helm | %APPDATA%\helm |
|
|
|
|
`
|
|
|
|
`
|
|
|
|
|
|
|
|
|
|
|
|
func newRootCmd(actionConfig *action.Configuration, out io.Writer, args []string) *cobra.Command {
|
|
|
|
func newRootCmd(actionConfig *action.Configuration, out io.Writer, args []string) (*cobra.Command, error) {
|
|
|
|
cmd := &cobra.Command{
|
|
|
|
cmd := &cobra.Command{
|
|
|
|
Use: "helm",
|
|
|
|
Use: "helm",
|
|
|
|
Short: "The Helm package manager for Kubernetes.",
|
|
|
|
Short: "The Helm package manager for Kubernetes.",
|
|
|
@ -175,10 +175,10 @@ func newRootCmd(actionConfig *action.Configuration, out io.Writer, args []string
|
|
|
|
registryClient, err := registry.NewClient(
|
|
|
|
registryClient, err := registry.NewClient(
|
|
|
|
registry.ClientOptDebug(settings.Debug),
|
|
|
|
registry.ClientOptDebug(settings.Debug),
|
|
|
|
registry.ClientOptWriter(out),
|
|
|
|
registry.ClientOptWriter(out),
|
|
|
|
|
|
|
|
registry.ClientOptCredentialsFile(settings.RegistryConfig),
|
|
|
|
)
|
|
|
|
)
|
|
|
|
if err != nil {
|
|
|
|
if err != nil {
|
|
|
|
// TODO: don't panic here, refactor newRootCmd to return error
|
|
|
|
return nil, err
|
|
|
|
panic(err)
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
actionConfig.RegistryClient = registryClient
|
|
|
|
actionConfig.RegistryClient = registryClient
|
|
|
|
cmd.AddCommand(
|
|
|
|
cmd.AddCommand(
|
|
|
@ -189,5 +189,5 @@ func newRootCmd(actionConfig *action.Configuration, out io.Writer, args []string
|
|
|
|
// Find and add plugins
|
|
|
|
// Find and add plugins
|
|
|
|
loadPlugins(cmd, out)
|
|
|
|
loadPlugins(cmd, out)
|
|
|
|
|
|
|
|
|
|
|
|
return cmd
|
|
|
|
return cmd, nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|