Skip to content

Commit

Permalink
Fix mangling package names in a multi-package workspace
Browse files Browse the repository at this point in the history
  • Loading branch information
johnewart committed May 7, 2019
1 parent 372b0e7 commit 77a01d0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion workspace/workspace.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ func (w Workspace) PackageList() ([]Package, error) {
panic(err)
}
if fi.IsDir() {
pkgName := strings.Replace(f, w.Path, "", 1)
_, pkgName := filepath.Split(f)
pkgPath := f
if !strings.HasPrefix(pkgName, ".") {
pkg, err := LoadPackage(pkgName, pkgPath)
Expand Down Expand Up @@ -136,6 +136,7 @@ func LoadWorkspace() (Workspace, error) {
log.Fatalf("Error loading workspace config!")
}

fmt.Printf("Workspace path: %s\n", workspacePath)
workspace.Path = workspacePath
return workspace, nil
}

0 comments on commit 77a01d0

Please sign in to comment.