diff --git a/command/workspace_new.go b/command/workspace_new.go index 88dc27da9..af7ad2265 100644 --- a/command/workspace_new.go +++ b/command/workspace_new.go @@ -77,6 +77,7 @@ func (c *WorkspaceNewCommand) Run(args []string) int { states, err := b.States() if err != nil { c.Ui.Error(fmt.Sprintf("Failed to get configured named states: %s", err)) + return 1 } for _, s := range states { if newEnv == s {