mirror of
https://github.com/vmware-tanzu/velero.git
synced 2026-09-19 22:44:21 +00:00
Add confirm flag to velero plugin add
Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>
This commit is contained in:
@@ -45,7 +45,7 @@ import (
|
||||
velerov2alpha1api "github.com/vmware-tanzu/velero/pkg/apis/velero/v2alpha1"
|
||||
"github.com/vmware-tanzu/velero/pkg/client"
|
||||
"github.com/vmware-tanzu/velero/pkg/cmd"
|
||||
"github.com/vmware-tanzu/velero/pkg/cmd/cli"
|
||||
"github.com/vmware-tanzu/velero/pkg/cmd/util/confirm"
|
||||
"github.com/vmware-tanzu/velero/pkg/controller"
|
||||
"github.com/vmware-tanzu/velero/pkg/install"
|
||||
kubeutil "github.com/vmware-tanzu/velero/pkg/util/kube"
|
||||
@@ -88,7 +88,7 @@ Use '--force' to skip the prompt confirming if you want to uninstall Velero.
|
||||
// Confirm if not asked to force-skip confirmation
|
||||
if !o.force {
|
||||
fmt.Println("You are about to uninstall Velero.")
|
||||
if !cli.GetConfirmation() {
|
||||
if !confirm.GetConfirmation() {
|
||||
// Don't do anything unless we get confirmation
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user