Add a hint about stack rm after successful destroy
@@ -16,6 +16,7 @@ package cmd
import (
"context"
+ "fmt"
"github.com/pkg/errors"
"github.com/spf13/cobra"
@@ -123,6 +124,13 @@ func newDestroyCmd() *cobra.Command {
SecretsManager: sm,
Scopes: cancellationScopes,
})
+
+ if res == nil {
+ fmt.Printf("The resources in the stack have been deleted, but the history and configuration "+
+ "associated with the stack are still maintained. \nIf you want to remove the stack "+
+ "completely, run 'pulumi stack rm %s'.\n", s.Ref())
+ }
+
if res != nil && res.Error() == context.Canceled {
return result.FromError(errors.New("destroy cancelled"))
}
