Take into consideration that path may contain multiple `status-go` directories, take the last (#776)

- Happens in Jenkins
This commit is contained in:
Pedro Pombeiro 2018-03-27 17:06:36 +02:00 committed by GitHub
parent c4d7a6167e
commit d9b28a06d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -63,7 +63,7 @@ func init() {
const pathSeparator = string(os.PathSeparator)
RootDir = filepath.Dir(pwd)
pathDirs := strings.Split(RootDir, pathSeparator)
for i := range pathDirs {
for i := len(pathDirs) - 1; i >= 0; i-- {
if pathDirs[i] == "status-go" {
RootDir = filepath.Join(pathDirs[:i+1]...)
RootDir = filepath.Join(pathSeparator, RootDir)