veracode package discover
Detects toolchains in your project and identifies any changes or upgrades needed to create scannable artifacts. It generates and updates the veracode.yml file with supported modules to reduce manual setup and improve scan accuracy. To learn more, see About package discover.
veracode package discover currently supports MSBuild (.NET), Maven (Java), and Gradle (Java) build tools.
Usage
./veracode package discover [path] [flags]
Flags
| Flag | Description |
|---|---|
-d, --dry-run | Runs the command without writing changes to the veracode.yml file. |
-f, --format <string> | Specifies the output format. Options: json, text, or yaml. Default is text. |
-h, --help | Displays help information for the discover command. |
-no, --update-check | Disables the automatic version update check. |
-v, --verbose <count> | Increases output verbosity |
Examples
To detect Maven modules in the current directory and generate or update veracode.yml, run:
./veracode package discover /path/to/mavenProject
To detect .NET SDK-style or classic projects and generate or update veracode.yml, run:
./veracode package discover /path/to/dotnetProject
To detect Gradle modules and generate or update veracode.yml, in the current directory, run:
./veracode package discover /path/to/gradleProject
To detect multi-module Gradle projects and produce a full list of all discovered build.gradle and build.gradle.kts files, run:
./veracode package discover /path/to/gradleMultiModuleProject
To display the configuration that would be written to veracode.yml in JSON format without modifying the file, run:
./veracode package discover . --dry-run --format yaml