move interactive option to global (#370)

Fixes #366

Signed-off-by: yxxhero <aiopsclub@163.com>
This commit is contained in:
yxxhero
2022-09-18 18:47:40 +09:00
committed by GitHub
parent 7d88370310
commit 18eee1fa47
10 changed files with 8 additions and 32 deletions
+7
View File
@@ -46,6 +46,8 @@ type GlobalOptions struct {
logger *zap.SugaredLogger
// EnableLiveOutput enables live output from the Helm binary stdout/stderr into Helmfile own stdout/stderr
EnableLiveOutput bool
// Interactive is true if the user should be prompted for input.
Interactive bool
}
// Logger returns the logger to use.
@@ -179,3 +181,8 @@ func (g *GlobalImpl) ValidateConfig() error {
}
return nil
}
// Interactive returns the Interactive
func (g *GlobalImpl) Interactive() bool {
return g.GlobalOptions.Interactive
}