tools

package
v0.4.31 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2020 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateCommand added in v0.4.28

func CreateCommand(tool Interface) *cobra.Command

Types

type DirectoryBasedToolOpts added in v0.4.28

type DirectoryBasedToolOpts struct {
	ToolOpts
	Directory string
	// contains filtered or unexported fields
}

func (*DirectoryBasedToolOpts) GetDirectory added in v0.4.28

func (o *DirectoryBasedToolOpts) GetDirectory() string

func (*DirectoryBasedToolOpts) Register added in v0.4.28

func (o *DirectoryBasedToolOpts) Register(cmd *cobra.Command)

type DockerTool added in v0.4.29

type DockerTool struct {
	Name       string
	Image      string
	Directory  string
	DockerArgs []string
	Args       []string
}

type HasCommandTemplate added in v0.4.31

type HasCommandTemplate interface {
	CommandTemplate() *cobra.Command
}

type Interface

type Interface interface {
	options.Interface
	GetToolOptions() *ToolOpts
	Run() (*Result, error)
	Name() string
}

type Result

type Result struct {
	Data         *jnode.Node
	Values       map[string]string
	Directory    string
	Files        *util.StringSet
	PrintPath    []string
	PrintColumns []string

	AssessmentURL string
}

func (*Result) AddFile added in v0.4.21

func (r *Result) AddFile(path string) *Result

func (*Result) AddValue added in v0.4.21

func (r *Result) AddValue(name, value string) *Result

func (*Result) Report added in v0.4.30

func (r *Result) Report(tool Interface) error

type ToolOpts

type ToolOpts struct {
	options.PrintClientOpts
	UploadEnabled bool
	OmitContext   bool
	ToolVersion   string
	ToolPath      string
	Internal      bool
}

func (*ToolOpts) GetToolOptions added in v0.4.28

func (o *ToolOpts) GetToolOptions() *ToolOpts

func (*ToolOpts) InstallAPIServerArtifact added in v0.4.28

func (o *ToolOpts) InstallAPIServerArtifact(name, urlPath string) (*download.Download, error)

func (*ToolOpts) InstallTool added in v0.4.29

func (o *ToolOpts) InstallTool(spec *download.Spec) (*download.Download, error)

func (*ToolOpts) Register

func (o *ToolOpts) Register(c *cobra.Command)

func (*ToolOpts) RunDocker added in v0.4.29

func (o *ToolOpts) RunDocker(d *DockerTool) ([]byte, error)

func (*ToolOpts) RunTool

func (o *ToolOpts) RunTool(tool Interface) (*Result, error)

func (*ToolOpts) SetContextValues

func (o *ToolOpts) SetContextValues(m map[string]string)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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