HellPot/extra/decorate.go

28 lines
467 B
Go
Raw Normal View History

package extra
import (
2021-10-17 17:09:28 +00:00
"os"
2021-09-15 21:25:02 +00:00
"runtime"
2021-10-17 17:09:28 +00:00
"github.com/yunginnanet/HellPot/config"
)
2021-10-17 17:09:28 +00:00
func bannerFail(errs ...error) {
println("failed printing banner, consider using --nocolor")
for _, err := range errs {
if err != nil {
println(err.Error())
}
}
os.Exit(1)
}
2021-09-15 19:17:32 +00:00
// Banner prints out our banner (using spooky magic)
func Banner() {
2021-09-15 19:17:32 +00:00
if runtime.GOOS == "windows" || config.NoColor {
2021-09-15 14:04:16 +00:00
println(config.Title + " " + config.Version)
return
}
2021-09-15 19:17:32 +00:00
PrintBanner()
}