From 58772c871b844b03382f22e72bbdb7ae8ffdf8c8 Mon Sep 17 00:00:00 2001 From: Jguer Date: Sat, 28 Apr 2018 11:53:10 +0100 Subject: [PATCH] Fixes #373 Signed-off-by: Jguer --- main.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/main.go b/main.go index d3604cf7..608a4c31 100644 --- a/main.go +++ b/main.go @@ -60,6 +60,14 @@ func initConfig() (err error) { err) defaultSettings(&config) } + if _, err = os.Stat(config.BuildDir); os.IsNotExist(err) { + err = os.MkdirAll(config.BuildDir, 0755) + if err != nil { + err = fmt.Errorf("Unable to create BuildDir directory:\n%s\n"+ + "The error was:\n%s", config.BuildDir, err) + return + } + } } }