handle the case where qmk_firmware exists but isn't a clone
This commit is contained in:
@@ -83,6 +83,15 @@ def setup(cli):
|
||||
if is_qmk_firmware(cli.args.home):
|
||||
cli.log.info('Found qmk_firmware at %s.', str(cli.args.home))
|
||||
|
||||
elif qmk_firmware.exists():
|
||||
path_str = str(qmk_firmware)
|
||||
|
||||
if qmk_firmware.name != 'qmk_firmware':
|
||||
cli.log.warning('Warning: %s does not end in "qmk_firmware". Did you mean to use "--home %s/qmk_firmware"?' % (path_str, path_str))
|
||||
|
||||
cli.log.error("Path '%s' exists but is not a qmk_firmware clone!", path_str)
|
||||
exit(1)
|
||||
|
||||
else:
|
||||
cli.log.error('Could not find qmk_firmware!')
|
||||
if yesno(clone_prompt):
|
||||
|
||||
Reference in New Issue
Block a user