Skip to main content

grype CLI reference

ModularPipelines.Grype provides strongly typed access to the grype CLI.

Executable prerequisite​

This package does not install the grype executable. Install it separately and ensure grype is available on PATH.

Follow the executable's official documentation for installation instructions.

Package installation​

dotnet add package ModularPipelines.Grype

Resolve the service with context.Tools.Grype. Projects using C# 13 or another .NET language can use context.Tools.Get<ModularPipelines.Grype.Services.IGrype>() instead.

Module example​

Resolve the service in a module, then select a command from the table below. A runnable example is omitted when no command has complete safety metadata:

var grype = context.Tools.Grype;

Global options​

Global options are rendered before the selected subcommand.

CLI optionPropertyAvailabilityDescription
--configConfigAll editionsgrype configuration file(s) to use
--profileProfileAll editionsconfiguration profiles to use
--quietQuietAll editionssuppress all logging output
--verboseVerboseAll editionsincrease verbosity (-v = info, -vv = debug)

Commands​

CLI commandOptions record
grype dbGrypeDbOptions
grype db checkGrypeDbCheckOptions
grype db deleteGrypeDbDeleteOptions
grype db diffGrypeDbDiffOptions
grype db importGrypeDbImportOptions
grype db listGrypeDbListOptions
grype db providersGrypeDbProvidersOptions
grype db searchGrypeDbSearchOptions
grype db search vulnGrypeDbSearchVulnOptions
grype db statusGrypeDbStatusOptions
grype db updateGrypeDbUpdateOptions
grype explainGrypeExplainOptions
grype versionGrypeVersionOptions