mirror of
https://github.com/minio/mc.git
synced 2025-11-12 01:02:26 +03:00
Add stderr to support piped nocolor output
This commit is contained in:
@@ -78,7 +78,7 @@ var (
|
||||
currThemeName = func() string {
|
||||
theme := GetDefaultThemeName()
|
||||
// if not a TTY disable color
|
||||
if !isatty(os.Stdout.Fd()) {
|
||||
if !isatty(os.Stdout.Fd()) || !isatty(os.Stderr.Fd()) {
|
||||
return "nocolor"
|
||||
}
|
||||
return theme
|
||||
|
||||
Reference in New Issue
Block a user