cleanup debug logs & remove duplicated output (#1348)

* cleanup debug logs

* avoid duplicate error messages

and this makes main.go use os and fmt package instead of log to avoid
touching global state
This commit is contained in:
namusyaka
2020-11-04 22:50:18 +08:00
committed by GitHub
parent 8b06045c70
commit 951b46e3c2
3 changed files with 8 additions and 11 deletions
+4 -3
View File
@@ -17,14 +17,15 @@ limitations under the License.
package main
import (
"log"
"fmt"
"os"
"github.com/kubernetes/kompose/cmd"
)
func main() {
if err := cmd.Execute(); err != nil {
log.SetFlags(0)
log.Fatal(err)
fmt.Fprintln(os.Stderr, err)
os.Exit(1)
}
}