grype/internal/bus/helpers.go
Olivier Boudet 9050883715
feat(outputs): allow to set multiple outputs (#648) (#1346)
* feat(outputs): allow to set multiple outputs (#648)

Signed-off-by: Olivier Boudet <o.boudet@gmail.com>
Signed-off-by: Olivier Boudet <olivier.boudet@cooperl.com>
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>

* feat(outputs): allow to set multiple outputs (#648)

review

Signed-off-by: Olivier Boudet <olivier.boudet@cooperl.com>
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>

* use syft format writter pattern and de-emphasize presenter package

Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>

---------

Signed-off-by: Olivier Boudet <o.boudet@gmail.com>
Signed-off-by: Olivier Boudet <olivier.boudet@cooperl.com>
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
Co-authored-by: Alex Goodman <wagoodman@users.noreply.github.com>
2023-07-11 17:37:17 +00:00

20 lines
274 B
Go

package bus
import (
"github.com/wagoodman/go-partybus"
"github.com/anchore/grype/grype/event"
)
func Exit() {
Publish(partybus.Event{
Type: event.CLIExit,
})
}
func Report(report string) {
Publish(partybus.Event{
Type: event.CLIReport,
Value: report,
})
}