Skip to content

Commit

Permalink
hide fingerprint commands
Browse files Browse the repository at this point in the history
  • Loading branch information
emilwareus committed Oct 18, 2023
1 parent 94560af commit 35970e7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
7 changes: 4 additions & 3 deletions internal/cmd/fingerprint/fingerprint.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@ func NewFingerprintCmd(fingerprinter fingerprint.IFingerprint) *cobra.Command {
short := "Fingerprints files to match against the Debricked knowledge base. [beta feature]"
long := fmt.Sprintf("Fingerprint files for identification in a given path and writes it to %s. [beta feature]\nThis hashes all files and matches them against the Debricked knowledge base.", fingerprint.OutputFileNameFingerprints)
cmd := &cobra.Command{
Use: "fingerprint [path]",
Short: short,
Long: long,
Use: "fingerprint [path]",
Short: short,
Hidden: true,
Long: long,
PreRun: func(cmd *cobra.Command, _ []string) {
_ = viper.BindPFlags(cmd.Flags())
},
Expand Down
2 changes: 2 additions & 0 deletions internal/cmd/scan/scan.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,8 @@ $ debricked scan . `+exampleFlags)
cmd.Flags().BoolVar(&noResolve, NoResolveFlag, false, `disables resolution of manifest files that lack lock files. Resolving manifest files enables more accurate dependency scanning since the whole dependency tree will be analysed.
For example, if there is a "go.mod" in the target path, its dependencies are going to get resolved onto a lock file, and latter scanned.`)
cmd.Flags().BoolVar(&noFingerprint, FingerprintFlag, false, "enables fingerprinting for undeclared component identification. Can be run as a standalone command [files fingerprint] with more granular options. [beta feature]")
cmd.Flags().MarkHidden(FingerprintFlag) //nolint:errcheck

viper.MustBindEnv(RepositoryFlag)
viper.MustBindEnv(CommitFlag)
viper.MustBindEnv(BranchFlag)
Expand Down

0 comments on commit 35970e7

Please sign in to comment.