Skip to content

Commit

Permalink
Merge pull request #760 from LandonTClipp/fix_ordering
Browse files Browse the repository at this point in the history
Fix issue with file ordering
  • Loading branch information
LandonTClipp committed Feb 15, 2024
2 parents d4e7f57 + d39a2a2 commit 3b25f39
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
6 changes: 3 additions & 3 deletions codecov.yml
@@ -1,11 +1,11 @@
coverage:
precision: 5
round: down
range: "65...100"
range: "40...100"
status:
patch:
default:
target: 65%
threshold: 5%
target: 40%
threshold: 35%
base: auto

11 changes: 10 additions & 1 deletion pkg/config/config.go
Expand Up @@ -614,7 +614,16 @@ func (c *Config) subPackages(
}
}

pathLog.Debug().Msg("subdirectory has a .go file, adding this path to packages config")
pathLog.Debug().Msg("subdirectory has a .go file")
goModExists, err := path.Parent().Join("go.mod").Exists()
if err != nil {
pathLog.Err(err).Msg("failed to determine if go.mod exists")
return err
}
if goModExists {
pathLog.Debug().Msg("found .go file, but go.mod exists. Skipping.")
return pathlib.ErrWalkSkipSubtree
}
subdirectoriesWithGoFiles = append(subdirectoriesWithGoFiles, path.Parent())
visitedDirs[path.Parent().String()] = nil
}
Expand Down

0 comments on commit 3b25f39

Please sign in to comment.