oops
This commit is contained in:
parent
e76894265e
commit
8dd47d59e3
9
main.go
9
main.go
|
@ -6,7 +6,6 @@ import (
|
|||
"fmt"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
"go.wit.com/dev/alexflint/arg"
|
||||
"go.wit.com/gui"
|
||||
|
@ -112,16 +111,12 @@ func main() {
|
|||
}
|
||||
}
|
||||
|
||||
pwd, _ := os.Getwd()
|
||||
basedir := strings.TrimPrefix(pwd, me.forge.GetGoSrc())
|
||||
basedir = strings.Trim(basedir, "/")
|
||||
me.startRepo = me.forge.Repos.FindByGoPath(basedir)
|
||||
|
||||
// todo: add this to forgepb
|
||||
me.startRepo = me.forge.FindWorkingDirRepo()
|
||||
|
||||
if me.startRepo == nil {
|
||||
msg := fmt.Sprint("Can not run if pwd is not a repo", basedir)
|
||||
pwd, _ := os.Getwd()
|
||||
msg := fmt.Sprint("Can not run if pwd is not a repo", pwd)
|
||||
badExit(errors.New(msg))
|
||||
}
|
||||
me.Enable()
|
||||
|
|
Loading…
Reference in New Issue