Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var RootCmd = &cobra.Command{ Use: "To analyze a single image: [image]. To compare two images: [image1] [image2]", Short: "Analyze a single image or compare two images.", Long: `Analyzes a single image or compares two images using the specifed analyzers/differs as indicated via flags (see documentation for available ones).`, Run: func(cmd *cobra.Command, args []string) { if validArgs, err := validateArgs(args); !validArgs { glog.Error(err.Error()) os.Exit(1) } utils.SetDockerEngine(eng) analyzeArgs := []string{} allAnalyzers := getAllAnalyzers() for _, name := range allAnalyzers { if *analyzeFlagMap[name] == true { analyzeArgs = append(analyzeArgs, name) } } if len(analyzeArgs) == 0 { analyzeArgs = allAnalyzers } var err error if len(args) == 1 { err = analyzeImage(args[0], analyzeArgs) } else { err = diffImages(args[0], args[1], analyzeArgs) } if err != nil { glog.Error(err) os.Exit(1) } }, }
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.