Skip to main content

analysis_fingerprint

Function analysis_fingerprint 

Source
pub fn analysis_fingerprint(config: &ResolvedConfig) -> String
Expand description

A stable hash of every input, other than the source files, that decides which dead-code findings a run of config reports.

The inputs:

  • the fallow version;
  • the detection config digest (merged user config after extends, external plugins, rule packs);
  • the settings that a surface changes after resolution: production mode, includeEntryExports, the effective rules, the type-aware mode, requirement and project list, the file size limit;
  • the root-relative path and content of the repository ignore files, the package.json files, the tsconfig*.json and jsconfig*.json files and the extends files they name, and every file that matches a built-in or external plugin config pattern.

File content is normalized (CRLF to LF, trailing newlines removed) and the entries are sorted, so two checkouts of one commit give the same value on every platform. Known exclusions: the global git excludes file and other machine environment outside the FALLOW_* variables.