Appease the gods of formatting.
This commit is contained in:
parent
e3fe9fac60
commit
11b9ff0c4f
1 changed files with 4 additions and 0 deletions
|
|
@ -7,12 +7,14 @@ import qmk.path
|
|||
from qmk.commands import dump_lines, parse_configurator_json
|
||||
from qmk.constants import GPL2_HEADER_C_LIKE, GENERATED_HEADER_C_LIKE
|
||||
|
||||
|
||||
class ModuleAPI(AttrDict):
|
||||
def __init__(self, **kwargs):
|
||||
super().__init__()
|
||||
for key, value in kwargs.items():
|
||||
self[key] = value
|
||||
|
||||
|
||||
MODULE_API_LIST = [
|
||||
ModuleAPI(ret_type='void', name='keyboard_pre_init', args='void', call_params='', ret_val=None),
|
||||
ModuleAPI(ret_type='void', name='keyboard_post_init', args='void', call_params='', ret_val=None),
|
||||
|
|
@ -20,6 +22,7 @@ MODULE_API_LIST = [
|
|||
ModuleAPI(ret_type='bool', name='process_record', args='uint16_t keycode, keyrecord_t *record', call_params='keycode, record', ret_val='true'),
|
||||
]
|
||||
|
||||
|
||||
@cli.argument('-o', '--output', arg_only=True, type=qmk.path.normpath, help='File to write to')
|
||||
@cli.argument('-q', '--quiet', arg_only=True, action='store_true', help="Quiet mode, only output error messages")
|
||||
@cli.argument('filename', type=qmk.path.FileType('r'), arg_only=True, completer=FilesCompleter('.json'), help='Configurator JSON file')
|
||||
|
|
@ -38,6 +41,7 @@ def generate_community_modules_h(cli):
|
|||
lines.append(f'{api.ret_type} {api.name}_{module}({api.args});')
|
||||
dump_lines(cli.args.output, lines, cli.args.quiet)
|
||||
|
||||
|
||||
@cli.argument('-o', '--output', arg_only=True, type=qmk.path.normpath, help='File to write to')
|
||||
@cli.argument('-q', '--quiet', arg_only=True, action='store_true', help="Quiet mode, only output error messages")
|
||||
@cli.argument('filename', type=qmk.path.FileType('r'), arg_only=True, completer=FilesCompleter('.json'), help='Configurator JSON file')
|
||||
|
|
|
|||
Loading…
Reference in a new issue