printer

package
v0.0.11 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 10, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

* Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. * * This product includes software developed at Datadog (https://www.datadoghq.com) Copyright 2024 Datadog, Inc.

* Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. * * This product includes software developed at Datadog (https://www.datadoghq.com) Copyright 2024 Datadog, Inc.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrintResult

func PrintResult(ctx context.Context, summary *model.Summary, printer *Printer, usingCustomQueries bool, sciInfo model.SCIInfo) error

PrintResult prints on output the summary results nolint:gocritic

func PrintScanDuration

func PrintScanDuration(ctx context.Context, elapsed time.Duration)

PrintScanDuration prints the scan duration

Types

type Printer

type Printer struct {
	Critical            color.RGBColor
	Medium              color.RGBColor
	High                color.RGBColor
	Low                 color.RGBColor
	Info                color.RGBColor
	Success             color.RGBColor
	Line                color.RGBColor
	VersionMessage      color.RGBColor
	ContributionMessage color.RGBColor
}

Printer wil print console output with colors Medium is for medium sevevity results High is for high sevevity results Low is for low sevevity results Info is for info sevevity results Success is for successful prints Line is the color to print the line with the vulnerability minVersion is a bool that if true will print the results output in a minimum version

func NewPrinter

func NewPrinter() *Printer

NewPrinter initializes a new Printer

func (*Printer) PrintBySev

func (p *Printer) PrintBySev(content, sev string) string

PrintBySev will print the output with the specific severity color given the severity of the result

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL