use user cache directory for remote helmfiles

Signed-off-by: Quan TRAN <account@itscaro.me>
This commit is contained in:
Quan TRAN
2022-02-12 17:52:52 +09:00
committed by Yusuke Kuoka
parent 242e601898
commit baafe702b2
2 changed files with 3 additions and 19 deletions
+1 -7
View File
@@ -998,12 +998,7 @@ func (a *App) visitStatesWithSelectorsAndRemoteSupport(fileOrDir string, converg
opts.Environment.OverrideValues = envvals
}
dir, err := a.getwd()
if err != nil {
return err
}
a.remote = remote.NewRemote(a.Logger, dir, a.readFile, a.directoryExistsAt, a.fileExistsAt)
a.remote = remote.NewRemote(a.Logger, "", a.readFile, a.directoryExistsAt, a.fileExistsAt)
f := converge
if opts.Filter {
@@ -2098,7 +2093,6 @@ func (a *App) ShowCacheDir(c ListConfigProvider) error {
func (a *App) CleanCacheDir(c ListConfigProvider) error {
if !directoryExistsAt(remote.CacheDir()) {
fmt.Printf("Nothing to remove in cache directory: %s\n", remote.CacheDir())
return nil
}
fmt.Printf("Cleaning up cache directory: %s\n", remote.CacheDir())