Documentation
¶
Index ¶
Constants ¶
View Source
const VERSION = "0.2.0"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CLI ¶
type CLI struct { Globals Version VersionCommand `cmd:"" help:"Print the version"` Inspect InspectCommand `cmd:"" help:"Inspect the path"` Summary SummaryCommand `cmd:"" help:"Get a summary of the report"` Diff DiffCommand `cmd:"" help:"Get a diff of two reports"` }
type DiffCommand ¶
type DiffCommand struct { ReportType string `kong:"args='',help='Set the report type',default='snyk',enum='snyk,trivy,gosec'"` Path string `kong:"args='',help='Set the path to current file',default='',type='path',example='/path/to/current-file.json'"` CompareTo string `kong:"args='',help='Set the path to previous file',default='',example='/path/to/previous-file.json'"` Export bool `kong:"help='Whether to export the result to a html file',default='false'"` OutputType string `kong:"args='',help='Set the output type',default='table',enum='matrix,table'"` ExportFilename string `kong:"args='',help='Set the filename of the exported html file',default='',example='report.html'"` }
func (*DiffCommand) Run ¶
func (c *DiffCommand) Run() error
type Globals ¶
type Globals struct { LogLevel logutil.Level `kong:"help='Set the logging level',default='INFO',enum='DEBUG,INFO,WARN,ERROR',env='LOG_LEVEL'"` PrettyLog bool `kong:"help='Whether to enable or disable colored logs output',default='false',env='PRETTY_LOG'" optional:""` Version VersionFlag `name:"version" help:"Print the version"` }
type InspectCommand ¶
type InspectCommand struct {
TargetDir string `short:"t" long:"target" description:"Target directory to inspect" default:"." type:"path"`
}
func (*InspectCommand) Run ¶
func (c *InspectCommand) Run() error
type SummaryCommand ¶
type SummaryCommand struct { ReportType string `kong:"args='',help='Set the report type',default='snyk',enum='snyk,trivy,gosec'"` Path string `kong:"args='',help='Set the path to current file',default='',example='/path/to/current-file.json'"` Export bool `kong:",help='Whether to export the result to a html file',default='false'"` OutputType string `kong:"args='',help='Set the output type',default='table',enum='matrix,table'"` ExportFilename string `kong:"args='',help='Set the filename of the exported html file',default='',example='report.html'"` }
func (*SummaryCommand) Run ¶
func (c *SummaryCommand) Run() error
type VersionCommand ¶
type VersionCommand struct { }
VersionCommand is the command to get the version of the tool
func (*VersionCommand) Run ¶
func (cmd *VersionCommand) Run() error
type VersionFlag ¶
type VersionFlag string
func (VersionFlag) BeforeApply ¶
func (VersionFlag) Decode ¶
func (v VersionFlag) Decode(ctx *kong.DecodeContext) error
func (VersionFlag) IsBool ¶
func (v VersionFlag) IsBool() bool
Click to show internal directories.
Click to hide internal directories.