From 86ba2608a1536c1552eb72f8ff3624cb0bc977c5 Mon Sep 17 00:00:00 2001 From: meyerjrr <33018450+meyerjrr@users.noreply.github.com> Date: Wed, 10 Jul 2024 20:40:41 +1000 Subject: [PATCH] pass in stdio to dupe profile prompt (#696) --- pkg/granted/registry/sync.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkg/granted/registry/sync.go b/pkg/granted/registry/sync.go index ba911cb0..801c8683 100644 --- a/pkg/granted/registry/sync.go +++ b/pkg/granted/registry/sync.go @@ -4,6 +4,7 @@ import ( "context" "errors" "fmt" + "os" "github.com/AlecAivazis/survey/v2" "github.com/common-fate/clio" @@ -73,7 +74,8 @@ func SyncProfileRegistries(ctx context.Context, interactive bool) error { in := survey.Select{Message: "Please select which option would you like to choose to resolve: ", Options: options} var selected string - err = testable.AskOne(&in, &selected) + withStdio := survey.WithStdio(os.Stdin, os.Stderr, os.Stderr) + err = testable.AskOne(&in, &selected, withStdio) if err != nil { return err }