summaryrefslogtreecommitdiff
path: root/lib/python
diff options
context:
space:
mode:
Diffstat (limited to 'lib/python')
-rw-r--r--lib/python/qmk/cli/__init__.py1
-rw-r--r--lib/python/qmk/cli/cformat.py4
-rw-r--r--lib/python/qmk/cli/flash.py2
-rw-r--r--lib/python/qmk/commands.py8
-rw-r--r--lib/python/qmk/info.py1
5 files changed, 9 insertions, 7 deletions
diff --git a/lib/python/qmk/cli/__init__.py b/lib/python/qmk/cli/__init__.py
index b797bf31e8..47f60c601b 100644
--- a/lib/python/qmk/cli/__init__.py
+++ b/lib/python/qmk/cli/__init__.py
@@ -9,6 +9,7 @@ from milc import cli
from . import cformat
from . import compile
from . import config
+from . import docs
from . import doctor
from . import flash
from . import hello
diff --git a/lib/python/qmk/cli/cformat.py b/lib/python/qmk/cli/cformat.py
index 600161c5c5..6bcd15a110 100644
--- a/lib/python/qmk/cli/cformat.py
+++ b/lib/python/qmk/cli/cformat.py
@@ -43,8 +43,8 @@ def cformat(cli):
# Empty array for files
files = []
# Core directories for formatting
- core_dirs = ['drivers', 'quantum', 'tests', 'tmk_core']
- ignores = ['tmk_core/protocol/usb_hid', 'quantum/template']
+ core_dirs = ['drivers', 'quantum', 'tests', 'tmk_core', 'platforms']
+ ignores = ['tmk_core/protocol/usb_hid', 'quantum/template', 'platforms/chibios']
# Find the list of files to format
if cli.args.files:
files.extend(normpath(file) for file in cli.args.files)
diff --git a/lib/python/qmk/cli/flash.py b/lib/python/qmk/cli/flash.py
index 87de72ef8d..cefb9ca31a 100644
--- a/lib/python/qmk/cli/flash.py
+++ b/lib/python/qmk/cli/flash.py
@@ -4,6 +4,7 @@ You can compile a keymap already in the repo or using a QMK Configurator export.
A bootloader must be specified.
"""
import subprocess
+from argparse import FileType
from milc import cli
@@ -26,6 +27,7 @@ def print_bootloader_help():
cli.echo('\tdfu-util-split-left')
cli.echo('\tdfu-util-split-right')
cli.echo('\tst-link-cli')
+ cli.echo('\tst-flash')
cli.echo('For more info, visit https://docs.qmk.fm/#/flashing')
diff --git a/lib/python/qmk/commands.py b/lib/python/qmk/commands.py
index a7e1d9a57f..4db4667a8e 100644
--- a/lib/python/qmk/commands.py
+++ b/lib/python/qmk/commands.py
@@ -7,6 +7,7 @@ import subprocess
import shlex
import shutil
+from milc import cli
import qmk.keymap
@@ -37,7 +38,7 @@ def create_make_command(keyboard, keymap, target=None):
return [make_cmd, ':'.join(make_args)]
-def compile_configurator_json(configurator_filename, bootloader=None):
+def compile_configurator_json(user_keymap, bootloader=None):
"""Convert a configurator export JSON file into a C file
Args:
@@ -52,9 +53,6 @@ def compile_configurator_json(configurator_filename, bootloader=None):
A command to run to compile and flash the C file.
"""
- # Parse the configurator json
- user_keymap = parse_configurator_json(configurator_filename)
-
# Write the keymap C file
qmk.keymap.write(user_keymap['keyboard'], user_keymap['keymap'], user_keymap['layout'], user_keymap['layers'])
@@ -86,4 +84,6 @@ def run(command, *args, **kwargs):
safecmd = ' '.join(safecmd)
command = [os.environ['SHELL'], '-c', safecmd]
+ cli.log.debug('Running command: %s', command)
+
return subprocess.run(command, *args, **kwargs)
diff --git a/lib/python/qmk/info.py b/lib/python/qmk/info.py
index e1ace5d51b..de7632e378 100644
--- a/lib/python/qmk/info.py
+++ b/lib/python/qmk/info.py
@@ -77,7 +77,6 @@ def _extract_config_h(info_data):
'device_ver': config_c.get('DEVICE_VER'),
'manufacturer': config_c.get('MANUFACTURER'),
'product': config_c.get('PRODUCT'),
- 'description': config_c.get('DESCRIPTION'),
}
return info_data