diff options
Diffstat (limited to 'bin')
| -rwxr-xr-x | bin/qmk | 10 |
1 files changed, 4 insertions, 6 deletions
| @@ -13,8 +13,8 @@ qmk_dir = script_dir.parent | |||
| 13 | python_lib_dir = Path(qmk_dir / 'lib' / 'python').resolve() | 13 | python_lib_dir = Path(qmk_dir / 'lib' / 'python').resolve() |
| 14 | sys.path.append(str(python_lib_dir)) | 14 | sys.path.append(str(python_lib_dir)) |
| 15 | 15 | ||
| 16 | # QMK CLI user config file | 16 | # Setup the CLI |
| 17 | config_file = Path(Path.home() / '.config/qmk/qmk.ini') | 17 | import milc # noqa |
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | def _check_modules(requirements): | 20 | def _check_modules(requirements): |
| @@ -24,7 +24,7 @@ def _check_modules(requirements): | |||
| 24 | for line in fd.readlines(): | 24 | for line in fd.readlines(): |
| 25 | line = line.strip().replace('<', '=').replace('>', '=') | 25 | line = line.strip().replace('<', '=').replace('>', '=') |
| 26 | 26 | ||
| 27 | if line[0] == '#': | 27 | if len(line) == 0 or line[0] == '#' or '-r' in line: |
| 28 | continue | 28 | continue |
| 29 | 29 | ||
| 30 | if '#' in line: | 30 | if '#' in line: |
| @@ -53,12 +53,10 @@ developer = False | |||
| 53 | _check_modules('requirements.txt') | 53 | _check_modules('requirements.txt') |
| 54 | 54 | ||
| 55 | # For developers additional modules are needed | 55 | # For developers additional modules are needed |
| 56 | if config_file.exists() and 'developer = True' in config_file.read_text(): | 56 | if milc.cli.config.user.developer: |
| 57 | developer = True | 57 | developer = True |
| 58 | _check_modules('requirements-dev.txt') | 58 | _check_modules('requirements-dev.txt') |
| 59 | 59 | ||
| 60 | # Setup the CLI | ||
| 61 | import milc # noqa | ||
| 62 | 60 | ||
| 63 | milc.EMOJI_LOGLEVELS['INFO'] = '{fg_blue}Ψ{style_reset_all}' | 61 | milc.EMOJI_LOGLEVELS['INFO'] = '{fg_blue}Ψ{style_reset_all}' |
| 64 | 62 | ||
