From b459f91a22481deb96bae72a40a91af9b15b3b19 Mon Sep 17 00:00:00 2001 From: Mikhail Klementev Date: Sun, 2 Dec 2018 03:16:34 +0000 Subject: [PATCH] Run bootstrap automatically on first run --- main.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/main.go b/main.go index 6c4d9eb..b3f0721 100644 --- a/main.go +++ b/main.go @@ -145,6 +145,15 @@ func main() { handleFallbacks(kcfg) + if !exists(usr.HomeDir + "/.out-of-tree") { + log.Println("First run, bootstrap...") + err = bootstrapHandler() + if err != nil { + log.Println("bootstrap error:", err) + } + return + } + switch kingpin.MustParse(app.Parse(os.Args[1:])) { case pewCommand.FullCommand(): err = pewHandler(kcfg, *path, *pewKernel, *pewBinary,