From 424a659bc5a79fa9ace2c54dfc66ee68cf2c6901 Mon Sep 17 00:00:00 2001 From: alessio Date: Mon, 19 Jun 2017 12:13:21 +0200 Subject: [PATCH] fixed pull #61 --- watcher/exec.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/watcher/exec.go b/watcher/exec.go index 7792228..70d658f 100644 --- a/watcher/exec.go +++ b/watcher/exec.go @@ -48,9 +48,9 @@ func (p *Project) goRun(channel chan bool, runner chan bool, wr *sync.WaitGroup) build = exec.Command(path, args...) } else { if _, err := os.Stat(filepath.Join(getEnvPath("GOBIN"), filepath.Base(p.path))); err == nil { - build = exec.Command(filepath.Join(getEnvPath("GOBIN"), filepath.Base(p.path)), params...) + build = exec.Command(filepath.Join(getEnvPath("GOBIN"), filepath.Base(p.path)), args...) } else if _, err := os.Stat(filepath.Join(getEnvPath("GOBIN"), filepath.Base(p.path)) + ".exe"); err == nil { - build = exec.Command(filepath.Join(getEnvPath("GOBIN"), filepath.Base(p.path))+".exe", params...) + build = exec.Command(filepath.Join(getEnvPath("GOBIN"), filepath.Base(p.path))+".exe", args...) } else { p.Buffer.StdLog = append(p.Buffer.StdLog, BufferOut{Time: time.Now(), Text: "Can't run a not compiled project"}) p.Fatal(err, "Can't run a not compiled project", ":")