diff options
author | Ryan <fauxpark@gmail.com> | 2020-10-07 10:46:10 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-06 16:46:10 -0700 |
commit | 2c9ffd47391b8dec98db94bef9b2f5c14a57cf94 (patch) | |
tree | 57f743159e972e3e2cd215ab256675d3c84d1832 /lib/python/qmk/cli/json2c.py | |
parent | 2013f6313430b977e557e482d30daa279a46e75d (diff) | |
download | qmk_firmware-2c9ffd47391b8dec98db94bef9b2f5c14a57cf94.tar.gz qmk_firmware-2c9ffd47391b8dec98db94bef9b2f5c14a57cf94.zip |
CLI: update subcommands to use return instead of exit() (#10323)
Diffstat (limited to 'lib/python/qmk/cli/json2c.py')
-rwxr-xr-x | lib/python/qmk/cli/json2c.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/python/qmk/cli/json2c.py b/lib/python/qmk/cli/json2c.py index af0d80a9a..2a9009436 100755 --- a/lib/python/qmk/cli/json2c.py +++ b/lib/python/qmk/cli/json2c.py | |||
@@ -22,12 +22,12 @@ def json2c(cli): | |||
22 | # TODO(skullydazed/anyone): Read file contents from STDIN | 22 | # TODO(skullydazed/anyone): Read file contents from STDIN |
23 | cli.log.error('Reading from STDIN is not (yet) supported.') | 23 | cli.log.error('Reading from STDIN is not (yet) supported.') |
24 | cli.print_usage() | 24 | cli.print_usage() |
25 | exit(1) | 25 | return False |
26 | 26 | ||
27 | if not cli.args.filename.exists(): | 27 | if not cli.args.filename.exists(): |
28 | cli.log.error('JSON file does not exist!') | 28 | cli.log.error('JSON file does not exist!') |
29 | cli.print_usage() | 29 | cli.print_usage() |
30 | exit(1) | 30 | return False |
31 | 31 | ||
32 | # Environment processing | 32 | # Environment processing |
33 | if cli.args.output and cli.args.output.name == '-': | 33 | if cli.args.output and cli.args.output.name == '-': |