You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fmt.Println: Use only when you are providing an actual output for the command that is running. Do not use this for intermediate info logs. For that, use utils.Logln or utils.Logf
utils.Logln: Provide verbose logs. Will be printed only when --verbose mode is enabled.
utils.Logf: Same as above, except it prints formatted logs
In error cases:
utils.HandleErrorAndExit: When the program cannot continue and it needs to exist after printing the error.
utils.HandleErrorAndContinue: When the program can continue but it needs to print the error.
Mind the streams:
stdout is only for the actual output of the command
stderr is for messages (not only error messages but also other info messages)