def METHOD_NAME(cli):
    """Generates the keycodes.h file.
    """
    # Build the keycodes.h file.
    keycodes_h_lines = [GPL2_HEADER_C_LIKE, GENERATED_HEADER_C_LIKE, '#pragma once', '// clang-format off']
    keycodes = load_spec(cli.args.version)
    _generate_ranges(keycodes_h_lines, keycodes)
    _generate_defines(keycodes_h_lines, keycodes)
    _generate_helpers(keycodes_h_lines, keycodes)
    # Show the results
    dump_lines(cli.args.output, keycodes_h_lines, cli.args.quiet)