Excluding files and rules

When you don't want to see the issues of some files (like external library file or test file) or rules, you can exclude those from the analysis.

Excluding Rules

Select or de-select the rules to exclude in Settings > Rules.

Then, click Apply button. By clicking Reanalyze button in the dialog, the changed rules do apply.

Exclude rules

Excluding Files from Settings

To exclude files in the settings, set file pattern in Settings > Exclusion.

File Pattern

You can specify the pattern of files or folders that you'd like to exclude from the analysis as follows:

  • Patterns are line-separated.
  • Each pattern follows the gitignore format.
  • Each pattern is relative to the project root.

For example,

  • To ignore all files named foo.js, just enter the filename like foo.js.
  • To ignore the specific file under test folder, just enter the file path like /test/foo.js.
  • To ignore all files under lib and test folder, enter /lib and /test at separate lines.

Exclude in settings

Excluding Files from Files

To exclude a file or directory directly in Files, click x button in the view.

Exclude in files