Commit c1a81c6f authored by Daniel Hiltgen's avatar Daniel Hiltgen
Browse files

Use stdin for term discovery on windows

When you feed input to the cmd via a pipe it no longer reports a warning
parent e72c567c
...@@ -900,8 +900,7 @@ func NewCLI() *cobra.Command { ...@@ -900,8 +900,7 @@ func NewCLI() *cobra.Command {
cobra.EnableCommandSorting = false cobra.EnableCommandSorting = false
if runtime.GOOS == "windows" { if runtime.GOOS == "windows" {
// Enable colorful ANSI escape code in Windows terminal (disabled by default) console.ConsoleFromFile(os.Stdin) //nolint:errcheck
console.ConsoleFromFile(os.Stdout) //nolint:errcheck
} }
rootCmd := &cobra.Command{ rootCmd := &cobra.Command{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment