Fix CLI unable to get pod logs from controller (#1451)

This commit is contained in:
Ta-Ching Chen
2019-12-01 22:38:35 +08:00
committed by GitHub
parent 4b3f48b537
commit 763ab475f2
4 changed files with 121 additions and 74 deletions
+5
View File
@@ -33,6 +33,11 @@ func Error(msg interface{}) {
os.Stderr.WriteString(fmt.Sprintf("%v: %v\n", color.RedString("Error"), trimNewline(msg)))
}
func Errorf(format string, args ...interface{}) {
msg := fmt.Sprintf(format, args...)
os.Stderr.WriteString(fmt.Sprintf("%v: %v\n", color.RedString("Error"), trimNewline(msg)))
}
func Warn(msg interface{}) {
os.Stdout.WriteString(fmt.Sprintf("%v: %v\n", color.YellowString("Warning"), trimNewline(msg)))
}