aboutsummaryrefslogtreecommitdiff
path: root/lib/python/qmk/cli/json/keymap.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/python/qmk/cli/json/keymap.py')
-rwxr-xr-xlib/python/qmk/cli/json/keymap.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/python/qmk/cli/json/keymap.py b/lib/python/qmk/cli/json/keymap.py
index 207ac278c..7b7553104 100755
--- a/lib/python/qmk/cli/json/keymap.py
+++ b/lib/python/qmk/cli/json/keymap.py
@@ -10,6 +10,7 @@ import qmk.keymap
10 10
11 11
12@cli.argument('-o', '--output', arg_only=True, help='File to write to') 12@cli.argument('-o', '--output', arg_only=True, help='File to write to')
13@cli.argument('-q', '--quiet', arg_only=True, action='store_true', help="Quiet mode, only output error messages")
13@cli.argument('filename', arg_only=True, help='Configurator JSON file') 14@cli.argument('filename', arg_only=True, help='Configurator JSON file')
14@cli.subcommand('Creates a keymap.c from a QMK Configurator export.') 15@cli.subcommand('Creates a keymap.c from a QMK Configurator export.')
15def json_keymap(cli): 16def json_keymap(cli):
@@ -48,7 +49,8 @@ def json_keymap(cli):
48 with open(output_file, 'w') as keymap_fd: 49 with open(output_file, 'w') as keymap_fd:
49 keymap_fd.write(keymap_c) 50 keymap_fd.write(keymap_c)
50 51
51 cli.log.info('Wrote keymap to %s.', cli.args.output) 52 if not cli.args.quiet:
53 cli.log.info('Wrote keymap to %s.', cli.args.output)
52 54
53 else: 55 else:
54 print(keymap_c) 56 print(keymap_c)