Skip to content

Commit c128d12

Browse files
authored
fix: use file depending on build configuration to invalidate cache (#6179)
1 parent b92f577 commit c128d12

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/cache/cache.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ func (c *Cache) computePkgHash(pkg *packages.Package) (hashResults, error) {
166166

167167
fmt.Fprintf(key, "pkgpath %s\n", pkg.PkgPath)
168168

169-
for _, f := range pkg.CompiledGoFiles {
169+
for _, f := range slices.Concat(pkg.CompiledGoFiles, pkg.IgnoredFiles) {
170170
h, fErr := c.fileHash(f)
171171
if fErr != nil {
172172
return nil, fmt.Errorf("failed to calculate file %s hash: %w", f, fErr)

0 commit comments

Comments
 (0)