fix(cli): protect Go install credentials

This commit is contained in:
ZacharyZhang-NY committed 2026-07-19 17:33:34 -04:00
1 parent 3488ab778c
commit 996672a6a7
16 files changed
+1128 -79

No files matched your search

+17
View File
@@ -0,0 +1,17 @@
//go:build !windows
package main
import (
"os"
"golang.org/x/term"
)
func isInteractiveTerminal(file *os.File) bool {
return term.IsTerminal(int(file.Fd()))
}
func readHiddenLine(file *os.File) ([]byte, error) {
return term.ReadPassword(int(file.Fd()))
}