|
|
@ -26,7 +26,6 @@ import (
|
|
|
|
"github.com/spf13/cobra"
|
|
|
|
"github.com/spf13/cobra"
|
|
|
|
|
|
|
|
|
|
|
|
"k8s.io/helm/pkg/chartutil"
|
|
|
|
"k8s.io/helm/pkg/chartutil"
|
|
|
|
"k8s.io/kubernetes/pkg/util/slice"
|
|
|
|
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
|
const inspectDesc = `
|
|
|
|
const inspectDesc = `
|
|
|
@ -256,9 +255,18 @@ func (i *inspectCmd) run() error {
|
|
|
|
|
|
|
|
|
|
|
|
func findReadme(files []*any.Any) (file *any.Any) {
|
|
|
|
func findReadme(files []*any.Any) (file *any.Any) {
|
|
|
|
for _, file := range files {
|
|
|
|
for _, file := range files {
|
|
|
|
if slice.ContainsString(readmeFileNames, strings.ToLower(file.TypeUrl), nil) {
|
|
|
|
if contains(readmeFileNames, strings.ToLower(file.TypeUrl)) {
|
|
|
|
return file
|
|
|
|
return file
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return nil
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
func contains(slice []string, s string) bool {
|
|
|
|
|
|
|
|
for _, item := range slice {
|
|
|
|
|
|
|
|
if item == s {
|
|
|
|
|
|
|
|
return true
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return false
|
|
|
|
|
|
|
|
}
|
|
|
|