flags

package
v1.4.5 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2021 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CIFlag             = "ci"
	LogFileFlag        = "log-file"
	LogFileShorthand   = "l"
	LogFormatFlag      = "log-format"
	LogFormatShorthand = "f"
	LogLevelFlag       = "log-level"
	LogPathFlag        = "log-path"
	NoColorFlag        = "no-color"
	ProfilingFlag      = "profiling"
	SilentFlag         = "silent"
	SilentShorthand    = "s"
	VerboseFlag        = "verbose"
	VerboseShorthand   = "v"
)

Flags constants for kics

View Source
const (
	BomFlag                = "bom"
	CloudProviderFlag      = "cloud-provider"
	ConfigFlag             = "config"
	DisableCISDescFlag     = "disable-cis-descriptions"
	DisableFullDescFlag    = "disable-full-descriptions"
	ExcludeCategoriesFlag  = "exclude-categories"
	ExcludePathsFlag       = "exclude-paths"
	ExcludeQueriesFlag     = "exclude-queries"
	ExcludeResultsFlag     = "exclude-results"
	ExcludeSeveritiesFlag  = "exclude-severities"
	IncludeQueriesFlag     = "include-queries"
	InputDataFlag          = "input-data"
	FailOnFlag             = "fail-on"
	IgnoreOnExitFlag       = "ignore-on-exit"
	MinimalUIFlag          = "minimal-ui"
	NoProgressFlag         = "no-progress"
	OutputNameFlag         = "output-name"
	OutputPathFlag         = "output-path"
	PathFlag               = "path"
	PayloadPathFlag        = "payload-path"
	PreviewLinesFlag       = "preview-lines"
	QueriesPath            = "queries-path"
	LibrariesPath          = "libraries-path"
	ReportFormatsFlag      = "report-formats"
	TypeFlag               = "type"
	QueryExecTimeoutFlag   = "timeout"
	LineInfoPayloadFlag    = "payload-lines"
	DisableSecretsFlag     = "disable-secrets"
	SecretsRegexesPathFlag = "secrets-regexes-path" //nolint:gosec
)

Flags constants for scan

Variables

This section is empty.

Functions

func GetBoolFlag

func GetBoolFlag(flagName string) bool

GetBoolFlag get a boolean flag by its name

func GetIntFlag

func GetIntFlag(flagName string) int

GetIntFlag get a integer flag by its name

func GetMultiStrFlag

func GetMultiStrFlag(flagName string) []string

GetMultiStrFlag get a slice of strings flag by its name

func GetStrFlag

func GetStrFlag(flagName string) string

GetStrFlag get a string flag by its name

func InitJSONFlags

func InitJSONFlags(cmd *cobra.Command, flagsListContent string, persistentFlag bool) error

InitJSONFlags initialize cobra flags

func SetMultiStrFlag

func SetMultiStrFlag(flagName string, value []string)

SetMultiStrFlag set a slice of strings flag using its name

func SetStrFlag

func SetStrFlag(flagName, value string)

SetStrFlag set a string flag using its name

func Validate

func Validate() error

Validate validate if flag values are ok, if not, returns an error

Types

This section is empty.

Jump to

Keyboard shortcuts

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