Skip to content

Commit

Permalink
linter: when subpackages are linted use the subpackage name as the pa…
Browse files Browse the repository at this point in the history
…ckage config name

Signed-off-by: James Rawlings <jrawlings@chainguard.dev>
  • Loading branch information
rawlingsj authored and Elizafox committed Sep 19, 2023
1 parent 7e7a042 commit 5913c2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/build/build.go
Original file line number Diff line number Diff line change
Expand Up @@ -1121,7 +1121,7 @@ func (b *Build) BuildPackage(ctx context.Context) error {
// TODO(Elizafox): getting the workspace dir path should be refactored.
path := filepath.Join(b.WorkspaceDir, "melange-out", sp.Name)
fsys := os.DirFS(path)
lctx := LinterContext{b.Configuration.Package.Name, &b.Configuration, &chk}
lctx := LinterContext{sp.Name, &b.Configuration, &chk}
err = lintPackageFs(lctx, fsys, linters)
if err != nil {
return fmt.Errorf("Error with package linter:\n%w", err)
Expand Down

0 comments on commit 5913c2c

Please sign in to comment.