MCPcopy Create free account
hub / github.com/Masterminds/glide / buildDep

Function buildDep

action/rebuild.go:43–62  ·  view source on GitHub ↗
(dep *cfg.Dependency, vpath string)

Source from the content-addressed store, hash-verified

41}
42
43func buildDep(dep *cfg.Dependency, vpath string) error {
44 if len(dep.Subpackages) == 0 {
45 buildPath(dep.Name)
46 }
47
48 for _, pkg := range dep.Subpackages {
49 if pkg == "**" || pkg == "..." {
50 //Info("Building all packages in %s\n", dep.Name)
51 buildPath(path.Join(dep.Name, "..."))
52 } else {
53 paths, err := resolvePackages(vpath, dep.Name, pkg)
54 if err != nil {
55 msg.Warn("Error resolving packages: %s", err)
56 }
57 buildPaths(paths)
58 }
59 }
60
61 return nil
62}
63
64func resolvePackages(vpath, pkg, subpkg string) ([]string, error) {
65 sdir, _ := os.Getwd()

Callers 1

RebuildFunction · 0.85

Calls 4

buildPathFunction · 0.85
resolvePackagesFunction · 0.85
buildPathsFunction · 0.85
WarnMethod · 0.80

Tested by

no test coverage detected