Skip to content

Commit

Permalink
scope lint
Browse files Browse the repository at this point in the history
  • Loading branch information
blampe committed Oct 24, 2024
1 parent e9e1432 commit deab4c6
Showing 1 changed file with 8 additions and 16 deletions.
24 changes: 8 additions & 16 deletions scripts/build.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,23 +143,15 @@ func execCommandOrLogFatal(cwd, name string, arg ...string) {

// Finds directories containing go.mod files in the repository.
func findGoModuleRoots() (result []string) {
var buf bytes.Buffer
cmd := exec.Command("git", "ls-files", "-z", "**go.mod")
cmd.Dir = "."
cmd.Stderr = os.Stderr
cmd.Stdout = &buf
if err := cmd.Run(); err != nil {
log.Fatal(err)
}
ms := strings.Split(buf.String(), string(rune(0)))
for _, m := range ms {
if m == "" {
continue
}
d := filepath.Dir(m)
result = append(result, d)
// Please **don't** add additional modules here.
return []string{
"go.mod",
"tools/go.mod",
"dynamic/go.mod",
"dynamic/test/pfprovider/go.mod",
"dynamic/internal/shim/go.mod",
"pkg/pf/tests/testdatagen/genrandom/go.mod",
}
return result
}

func latestPulumiVersion() string {
Expand Down

0 comments on commit deab4c6

Please sign in to comment.