aboutsummaryrefslogtreecommitdiff
path: root/lib/python/qmk/cli/doctor.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/python/qmk/cli/doctor.py')
-rwxr-xr-xlib/python/qmk/cli/doctor.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/python/qmk/cli/doctor.py b/lib/python/qmk/cli/doctor.py
index 309de0c67..c2723bfcb 100755
--- a/lib/python/qmk/cli/doctor.py
+++ b/lib/python/qmk/cli/doctor.py
@@ -24,8 +24,7 @@ def doctor(cli):
24 cli.log.info('QMK Doctor is checking your environment.') 24 cli.log.info('QMK Doctor is checking your environment.')
25 25
26 # Make sure the basic CLI tools we need are available and can be executed. 26 # Make sure the basic CLI tools we need are available and can be executed.
27 binaries = ['dfu-programmer', 'avrdude', 'dfu-util', 'avr-gcc', 'arm-none-eabi-gcc'] 27 binaries = ['dfu-programmer', 'avrdude', 'dfu-util', 'avr-gcc', 'arm-none-eabi-gcc', 'bin/qmk']
28 binaries += glob('bin/qmk-*')
29 ok = True 28 ok = True
30 29
31 for binary in binaries: 30 for binary in binaries:
@@ -34,10 +33,10 @@ def doctor(cli):
34 cli.log.error("{fg_red}QMK can't find %s in your path.", binary) 33 cli.log.error("{fg_red}QMK can't find %s in your path.", binary)
35 ok = False 34 ok = False
36 else: 35 else:
37 try: 36 check = subprocess.run([binary, '--version'], stdout=subprocess.PIPE, stderr=subprocess.PIPE, timeout=5)
38 subprocess.run([binary, '--version'], stdout=subprocess.PIPE, stderr=subprocess.PIPE, timeout=5, check=True) 37 if check.returncode in [0, 1]:
39 cli.log.info('Found {fg_cyan}%s', binary) 38 cli.log.info('Found {fg_cyan}%s', binary)
40 except subprocess.CalledProcessError: 39 else:
41 cli.log.error("{fg_red}Can't run `%s --version`", binary) 40 cli.log.error("{fg_red}Can't run `%s --version`", binary)
42 ok = False 41 ok = False
43 42