2.1.23.7.8. cli.pre_commit_scripts.check_license_info.compare_header

cli.pre_commit_scripts.check_license_info.compare_header(file_name: Path, expected: list[str], actual: list[str], start: int, end: int) int

Compare the actual header in a file with the expected license header.

Parameters:
  • file_name – Path to the file being checked.

  • expected – The expected license header lines.

  • actual – The actual lines from the file.

  • start – Start index in the file lines to compare.

  • end – End index in the file lines to compare.

Returns:

1 if the header differs, 0 if it matches.