mirror of
https://github.com/fiatjaf/nak.git
synced 2025-12-08 16:48:51 +00:00
use color.Output and color.Error instead of os.Stdout and os.Stderr in some places.
This commit is contained in:
@@ -130,7 +130,7 @@ var blossomCmd = &cli.Command{
|
||||
hasError = true
|
||||
continue
|
||||
}
|
||||
os.Stdout.Write(data)
|
||||
stdout(data)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ const (
|
||||
var (
|
||||
log = func(msg string, args ...any) { fmt.Fprintf(color.Error, msg, args...) }
|
||||
logverbose = func(msg string, args ...any) {} // by default do nothing
|
||||
stdout = fmt.Println
|
||||
stdout = func(args ...any) { fmt.Fprintln(color.Output, args...) }
|
||||
)
|
||||
|
||||
func isPiped() bool {
|
||||
|
||||
Reference in New Issue
Block a user