(paths []string, fullPath bool, rootPath string)
| 41 | } |
| 42 | |
| 43 | func GetNewPaths(paths []string, fullPath bool, rootPath string) []string { |
| 44 | paths = cleanPath(paths, fullPath) |
| 45 | var path = env.GetModulesDir() |
| 46 | |
| 47 | matches, _ := ioutil.ReadDir(path) |
| 48 | |
| 49 | for _, value := range matches { |
| 50 | |
| 51 | var packagePath = filepath.Join(path, value.Name(), consts.FilePackage) |
| 52 | if _, err := os.Stat(packagePath); !os.IsNotExist(err) { |
| 53 | |
| 54 | other, _ := models.LoadPackageOther(packagePath) |
| 55 | paths = getNewPathsFromDir(filepath.Join(path, value.Name(), other.MainSrc), paths, fullPath, rootPath) |
| 56 | |
| 57 | } else { |
| 58 | paths = getNewPathsFromDir(filepath.Join(path, value.Name()), paths, fullPath, rootPath) |
| 59 | } |
| 60 | } |
| 61 | return paths |
| 62 | } |
| 63 | |
| 64 | func getDefaultPath(fullPath bool, rootPath string) []string { |
| 65 | var paths []string |
no test coverage detected