#148 workaround fixed

This commit is contained in:
asoseil 2018-01-09 00:50:49 +01:00
parent b9efc9d317
commit 930f2a3562

View File

@ -575,8 +575,10 @@ func (p *Project) run(path string, stream chan Response, stop <-chan bool) (err
dirPath, _ = filepath.Abs(p.Tools.Run.Dir)
}
name := filepath.Base(path)
if path == "." {
if path == "." && p.Tools.Run.Dir == "" {
name = filepath.Base(Wdir())
}else{
name = filepath.Base(dirPath)
}
path = filepath.Join(dirPath, name)
if _, err := os.Stat(path); err == nil {