Pass --keep-history when so instructed [#24]

This commit is contained in:
Erin Call
2020-01-02 10:58:58 -08:00
parent 7d750f097d
commit 17724e7015
7 changed files with 32 additions and 7 deletions

View File

@@ -6,9 +6,10 @@ import (
// Uninstall is an execution step that calls `helm uninstall` when executed.
type Uninstall struct {
Release string
DryRun bool
cmd cmd
Release string
DryRun bool
KeepHistory bool
cmd cmd
}
// Execute executes the `helm uninstall` command.
@@ -36,6 +37,9 @@ func (u *Uninstall) Prepare(cfg Config) error {
if u.DryRun {
args = append(args, "--dry-run")
}
if u.KeepHistory {
args = append(args, "--keep-history")
}
args = append(args, u.Release)