Skip to content
This repository was archived by the owner on Feb 16, 2023. It is now read-only.

Commit 465b8da

Browse files
committed
Remove prompt for setup code
There is no valid use case where a user would have to enter it manually, so we can better remove this altogehter and direct users to the website.
1 parent ac08b03 commit 465b8da

1 file changed

Lines changed: 2 additions & 7 deletions

File tree

internals/secrethub/init.go

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,6 @@ import (
66
"os"
77
"time"
88

9-
"github.com/secrethub/secrethub-go/internals/api"
10-
119
"github.com/secrethub/secrethub-cli/internals/cli/progress"
1210
"github.com/secrethub/secrethub-cli/internals/cli/ui"
1311
"github.com/secrethub/secrethub-cli/internals/secrethub/command"
@@ -128,11 +126,8 @@ func (cmd *InitCommand) Run() error {
128126
case InitModeSetupCode:
129127
setupCode := cmd.setupCode
130128
if setupCode == "" {
131-
var err error
132-
setupCode, err = ui.AskAndValidate(cmd.io, "What is your setup code?\n", 3, api.ValidateSetupCode)
133-
if err != nil {
134-
return err
135-
}
129+
fmt.Fprintln(cmd.io.Output(), "If you have signed up on https://signup.secrethub.io, just copy the provided `secrethub init` command to get your CLI set up.")
130+
return nil
136131
}
137132

138133
fmt.Fprintf(cmd.io.Output(), credentialCreationMessage, credentialPath)

0 commit comments

Comments
 (0)