Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 0ecc1bf

Browse files
committed
Bring back tty check
1 parent f24101a commit 0ecc1bf

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

cli/login.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ func login() *cobra.Command {
4545
}
4646
if !hasInitialUser {
4747
// TODO: Bryan - is this check correct on windows?
48-
// if !isTTY(cmd.InOrStdin()) {
49-
// return xerrors.New("the initial user cannot be created in non-interactive mode. use the API")
50-
// }
48+
if !isTTY(cmd.InOrStdin()) {
49+
return xerrors.New("the initial user cannot be created in non-interactive mode. use the API")
50+
}
5151
_, _ = fmt.Fprintf(cmd.OutOrStdout(), "%s Your Coder deployment hasn't been set up!\n", color.HiBlackString(">"))
5252

5353
_, err := runPrompt(cmd, &promptui.Prompt{

0 commit comments

Comments
 (0)