Skip to main content

Configure Ignore Patterns to Exclude Paths

Keep Vibgrate scans focused by excluding generated, vendored, or irrelevant paths with the --exclude flag or config exclusions, so the DriftScore reflects code you maintain.

Difficulty
Intermediate
Duration
12 minutes
Steps
5

Generated code, vendored libraries, and fixtures rarely belong in a drift scan. Vibgrate lets you exclude paths so the scan and the resulting DriftScore reflect the code you actually maintain. You can exclude paths ad hoc with --exclude or persist them in the config file.

Prerequisites

  • Vibgrate CLI installed
  • A project with paths worth excluding

Steps

1. Identify paths to skip

Look for directories that are generated, vendored, or otherwise outside your maintenance scope, such as build output or third-party copies.

2. Exclude paths on the command line

Use --exclude to skip a path for a single run.

vg scan --exclude dist

3. Persist exclusions in config

For durable, team-wide exclusions, set them in vibgrate.config.ts, which supports thresholds, scanner toggles, and exclusions. This way every scan and CI run honors the same scope.

4. Re-scan and compare

Run the scan again and confirm the excluded paths no longer appear in the findings.

vg

5. Confirm the DriftScore reflects scope

Because excluded paths no longer contribute findings, the DriftScore now reflects only the code in scope, giving you a more honest measure of maintainable drift.

Verification

After excluding a path, re-run the scan and confirm findings from that path are gone. The DriftScore should reflect the narrowed scope. If a path still appears, check that the exclusion in the config file matches the directory.

Next Steps

  • Tune thresholds and scanner toggles in vibgrate.config.ts.
  • Scope scans to a single package in a monorepo.
  • Track the in-scope DriftScore with a baseline.

Prerequisites

  • Vibgrate CLI installed
  • A project with paths to exclude

Steps

  • 1
    Identify paths to skip
  • 2
    Exclude paths on the command line
  • 3
    Persist exclusions in config
  • 4
    Re-scan and compare
  • 5
    Confirm the DriftScore reflects scope

Category

Vibgrate