func GrapnelMain() { log.SetFlags(0) rootCmd.Help = fmt.Sprintf("Defaults:\n") + fmt.Sprintf(" Lock file = %s\n", defaultLockFileName) + fmt.Sprintf(" Package file = %s\n", defaultPackageFileName) + fmt.Sprintf(" Config file path = %s\n", strings.Join(configFilePath, ", ")+ "\n"+rootCmd.Help) if err := rootCmd.Execute(os.Args...); err != nil { log.Error(err) rootCmd.ShowHelp(os.Args[0]) } }
func InitTestLogging() { log.SetGlobalLogLevel(log.DEBUG) log.SetFlags(0) }