scan
Scan a local directory for accidentally committed secrets (API keys, tokens, private keys, and similar credentials) before publishing it. This is the same secrets pre-check that nsyte deploy runs by default; running scan explicitly is useful in CI or as a standalone audit. The command exits with status 1 when at least one finding is reported and 0 when the directory is clean.
Usage
bash
nsyte scan [folder] [options]Arguments
[folder]— Directory to scan. Defaults to the current working directory.
Options
--scan-level <level>— Scan sensitivity level:low,medium, orhigh(default:medium). Unknown values fall back tomedium.-q, --quiet— Show summary only, no findings detail (default:false)-v, --verbose— Show verbose output with extra context (default:false)
Examples
Scan the current directory at the default sensitivity:
bash
nsyte scanScan a specific build directory at high sensitivity, summary only (CI-friendly):
bash
nsyte scan dist --scan-level high --quietScan with extra context for each finding:
bash
nsyte scan ./public --verboseSee Also
nsyte deploy— Deploy a directory;scanruns as a pre-check by default. Pass--skip-secrets-scanto disable.
Inherits global options. See global options.