Skip to content

Suppress Command

David Alcantar edited this page May 17, 2023 · 5 revisions

The Suppress command suppresses issues identified in a DevSkim Sarif.

Syntax

Usage: devskim suppress [arguments] [options]

Arguments:
  -I, --source-code          Required. Path to the parent directory containing the source code that was scanned to 
                             produce the sarif.
  -O, --sarif-result         Required. Filename for the output sarif from DevSkim Analyze.

Options:
  --dry-run                  Print information about files that would be changed without changing them.
  --all                      Apply all ignores.
  --files                    Comma separated list of paths to apply ignore to.
  --rules                    Comma separated list of rules to apply ignore for.
  --prefer-multiline         Prefer using multi-line formatted suppression comments. (Default: false) 
  --duration                 Optional duration for suppressions in days from current system time. (Default: 0)
  --languages                Path to custom json formatted Language file to specify languages. 
                             When specified, --comments must also be specified.
  --comments                 Path to custom json formatted Comments file to specify comments. 
                             When specified, --languages must also be specified.
  --reviewer                 Set an optional reviewer name to be associated with added suppressions.
  -x, --console-verbosity    Console verbosity [Verbose|Debug|Information|Warning|Error|Fatal]. (Default: Information)
  --disable-console          Disable console output of logging messages. (Default: false) 
  -v, --log-file-level       Log file level [Verbose|Debug|Information|Warning|Error|Fatal]. (Default: Error) 
  -l, --log-file-path        Log file path. If not set, will not log to file.
  --help                     Show help information.
  --version                  Display version information.

Example

devskim suppress -I /home/user/myproject/ -O /home/user/myproject/DevSkim.sarif