Skip to content

CLI Reference

This guide provides a comprehensive list of all command-line options and flags available in Code PathFinder.

Basic Syntax

Terminal window
pathfinder <SUB_COMMAND> --help
Code Pathfinder is designed for identifying vulnerabilities in source code.
Usage:
pathfinder [command]
Available Commands:
ci Scan a project for vulnerabilities with ruleset in ci mode
completion Generate the autocompletion script for the specified shell
help Help about any command
query Execute queries on the source code
scan Scan a project for vulnerabilities with ruleset
version Print the version and commit information
Flags:
--disable-metrics Disable metrics collection
-h, --help help for pathfinder
Use "pathfinder [command] --help" for more information about a command.

Flags

OptionDescription
--project <project_dir>Path to project directory to run analysis
---query "TYPE"Query to execute on the project
---query-file <query.cql>Execute query from CQL file
--output TYPEOutput format. json is the only supported format for now
--output-file FILE.jsonOutput file path with name to write the result.
--stdin trueLaunch stdin query console interactive way to query
--versionPrint installed version and commit tag information