In my program there is a lot places where I should create logs like following
log.Println("[Build]: bla bla“)
log.Println(“[INFO]: bla bla“)
log.Printf(“[ERROR]: bla bla“)
log.Println(“[WARNING]: bla bla“)
I use it for all my logging in different packages inside the application and it’s bit frustrating to copy this, is there a way to create some generic log which I can simple re-use it inside my program.
I read about logrus etc but they provide some way to do it but not provide some custom way or maybe I miss something.
My program is command line tool