mirror of
https://github.com/anchore/syft.git
synced 2026-10-12 06:07:20 +02:00
allow disabling all package catalogers (#3468)
Signed-off-by: tomersein <tomersein@gmail.com>
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
|||||||
"runtime/debug"
|
"runtime/debug"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
|
"github.com/anchore/syft/internal/log"
|
||||||
"github.com/anchore/syft/internal/task"
|
"github.com/anchore/syft/internal/task"
|
||||||
"github.com/anchore/syft/syft/cataloging"
|
"github.com/anchore/syft/syft/cataloging"
|
||||||
"github.com/anchore/syft/syft/cataloging/filecataloging"
|
"github.com/anchore/syft/syft/cataloging/filecataloging"
|
||||||
@@ -267,7 +268,8 @@ func (c *CreateSBOMConfig) packageTasks(src source.Description) ([]task.Task, *t
|
|||||||
finalTasks = append(finalTasks, persistentTasks...)
|
finalTasks = append(finalTasks, persistentTasks...)
|
||||||
|
|
||||||
if len(finalTasks) == 0 {
|
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
|
return finalTasks, &selection, nil
|
||||||
|
|||||||
Reference in New Issue
Block a user