(filename, style)
| 514 | write_file_lines(filename, file_lines) |
| 515 | |
| 516 | def exec_insert_header(filename, style): |
| 517 | file_lines = read_file_lines(filename) |
| 518 | if file_already_has_core_copyright(file_lines): |
| 519 | sys.exit('*** %s already has a copyright by The Bitcoin Core developers' |
| 520 | % (filename)) |
| 521 | start_year, end_year = get_git_change_year_range(filename) |
| 522 | if style in ['python', 'shell']: |
| 523 | insert_script_header(filename, file_lines, start_year, end_year) |
| 524 | else: |
| 525 | insert_cpp_header(filename, file_lines, start_year, end_year) |
| 526 | |
| 527 | ################################################################################ |
| 528 | # insert cmd |
no test coverage detected