Skip to content

Commit

Permalink
allow disabling all package catalogers (#3468)
Browse files Browse the repository at this point in the history
Signed-off-by: tomersein <[email protected]>
  • Loading branch information
tomersein authored Jan 16, 2025
1 parent c359c76 commit 6b2d73d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion syft/create_sbom_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"runtime/debug"
"strings"

"github.com/anchore/syft/internal/log"
"github.com/anchore/syft/internal/task"
"github.com/anchore/syft/syft/cataloging"
"github.com/anchore/syft/syft/cataloging/filecataloging"
Expand Down Expand Up @@ -267,7 +268,8 @@ func (c *CreateSBOMConfig) packageTasks(src source.Description) ([]task.Task, *t
finalTasks = append(finalTasks, persistentTasks...)

if len(finalTasks) == 0 {
return nil, nil, fmt.Errorf("no catalogers selected")
log.Warn("no catalogers selected")
return finalTasks, &selection, nil
}

return finalTasks, &selection, nil
Expand Down

0 comments on commit 6b2d73d

Please sign in to comment.