Return the make exit code for qmk compile and flash (#11402)

miryoku-merge-master
Zach White 5 years ago committed by GitHub
parent 2e9d091960
commit c07543133a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -48,7 +48,8 @@ def compile(cli):
cli.log.info('Compiling keymap with {fg_cyan}%s', ' '.join(command)) cli.log.info('Compiling keymap with {fg_cyan}%s', ' '.join(command))
if not cli.args.dry_run: if not cli.args.dry_run:
cli.echo('\n') cli.echo('\n')
subprocess.run(command) compile = subprocess.run(command)
return compile.returncode
else: else:
cli.log.error('You must supply a configurator export, both `--keyboard` and `--keymap`, or be in a directory for a keyboard or keymap.') cli.log.error('You must supply a configurator export, both `--keyboard` and `--keymap`, or be in a directory for a keyboard or keymap.')

@ -81,7 +81,8 @@ def flash(cli):
cli.log.info('Compiling keymap with {fg_cyan}%s', ' '.join(command)) cli.log.info('Compiling keymap with {fg_cyan}%s', ' '.join(command))
if not cli.args.dry_run: if not cli.args.dry_run:
cli.echo('\n') cli.echo('\n')
subprocess.run(command) compile = subprocess.run(command)
return compile.returncode
else: else:
cli.log.error('You must supply a configurator export, both `--keyboard` and `--keymap`, or be in a directory for a keyboard or keymap.') cli.log.error('You must supply a configurator export, both `--keyboard` and `--keymap`, or be in a directory for a keyboard or keymap.')

Loading…
Cancel
Save