fix(pkg/cli): do not override users xdg directories

Signed-off-by: Adam Reese <adam@reese.io>
pull/6362/head
Adam Reese 5 years ago
parent 180db556aa
commit b4788481b7
No known key found for this signature in database
GPG Key ID: 06F35E60A7A18DD6

@ -29,7 +29,6 @@ import (
"github.com/spf13/pflag" "github.com/spf13/pflag"
"helm.sh/helm/pkg/helmpath" "helm.sh/helm/pkg/helmpath"
"helm.sh/helm/pkg/helmpath/xdg"
) )
// EnvSettings describes all of the environment settings. // EnvSettings describes all of the environment settings.
@ -106,9 +105,6 @@ func (s *EnvSettings) setHelmEnvVars() {
"HELM_REPOSITORY_CONFIG": s.RepositoryConfig, "HELM_REPOSITORY_CONFIG": s.RepositoryConfig,
"HELM_REPOSITORY_CACHE": s.RepositoryCache, "HELM_REPOSITORY_CACHE": s.RepositoryCache,
"HELM_PLUGIN": s.PluginsDirectory, "HELM_PLUGIN": s.PluginsDirectory,
xdg.CacheHomeEnvVar: helmpath.CachePath(),
xdg.ConfigHomeEnvVar: helmpath.ConfigPath(),
xdg.DataHomeEnvVar: helmpath.DataPath(),
} { } {
if eVal := os.Getenv(key); len(eVal) > 0 { if eVal := os.Getenv(key); len(eVal) > 0 {
val = eVal val = eVal

Loading…
Cancel
Save