summaryrefslogtreecommitdiffstats
path: root/lib/python/qmk/commands.py
Commit message (Collapse)AuthorAgeFilesLines
* Remove bin/qmk (#14231)Zach White2021-08-291-1/+1
| | | | | * Remove the bin/qmk script * remove bin/qmk from workflows
* `--parallel` improvements (#13800)ruro2021-08-181-3/+20
| | | | | | | * improve make parallel jobs support * document the --parallel option * disable the output-sync for interactive targets
* Port new_keyboard.sh to CLI (#13706)Ryan2021-07-301-0/+9
| | | Co-authored-by: Erovia <Erovia@users.noreply.github.com>
* CLI: Add git and venv info to doctor's output (#13405)Erovia2021-07-101-1/+70
| | | | Most of the checks are saved from zvecr's retired 'up/status' subcommand PR.
* CLI: Add subcommand to generate version.h (#13151)Ryan2021-06-271-24/+38
|
* Merge remote-tracking branch 'origin/master' into developZach White2021-05-191-21/+2
|\ | | | | | | | | | | Resolved Conflicts: lib/python/qmk/tests/test_cli_commands.py util/install/fedora.sh
| * Align our subprocess usage with current best practices. (#12940)Zach White2021-05-191-21/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Align our subprocess usage with current best practices. * remove unused import * Apply suggestions from code review Co-authored-by: Ryan <fauxpark@gmail.com> * fix the cpp invocation for older python * allow for unprompted installation * make sure qmk new-keyboard works on windows Co-authored-by: Ryan <fauxpark@gmail.com>
* | Merge remote-tracking branch 'origin/master' into developQMK Bot2021-05-091-1/+1
|\|
| * CLI: Use BASH if SHELL variable is not set (Windows) (#12847)Erovia2021-05-091-1/+1
| |
* | Merge remote-tracking branch 'origin/master' into developQMK Bot2021-05-091-6/+28
|\|
| * Allow MAKE environment override for 'qmk clean' (#12473)Joel Challis2021-05-091-6/+28
| |
* | Merge remote-tracking branch 'origin/master' into developQMK Bot2021-03-241-0/+10
|\|
| * Add support for qmk_configurator style aliases (#11954)Zach White2021-03-241-0/+10
| | | | | | | | | | | | | | | | | | * Add support for qmk_configurator style aliases * add the keyboard aliases to the api data * add support for a keyboard metadata file * make flake8 happy
* | Consistently use bin/qmk when that script is called (#12286)Zach White2021-03-181-1/+1
| | | | | | | | | | * Pass QMK_BIN down to build_keyboard.mk * choose the correct qmk script
* | Merge remote-tracking branch 'origin/master' into developQMK Bot2021-03-091-1/+1
|\|
| * Fix typo in `get_git_version()` (#12182)Ryan2021-03-101-1/+1
| |
* | Begin the process of deprecating bin/qmk in favor of the global cli (#12109)Zach White2021-03-071-0/+1
|/ | | | | * Begin the process of deprecating bin/qmk in favor of the global cli * Correctly set the qmk bin
* CLI: Fix json flashing (#11765)Erovia2021-02-011-1/+4
|
* Fix QMK_BUILDDATE (#11641)Zach White2021-01-201-1/+1
|
* Generate version.h when compiling json files (#11581)Zach White2021-01-171-3/+55
| | | | | | | | | * generate version.h when compiling json files * make flake8 happy * fix formatting and verbose * quiet up the compile output
* Improve the compile and flash subcommands (#11334)Zach White2021-01-161-12/+81
| | | | | | | | | | | | | | | | | | | * add support for --clean to compile and flash * compile standalone JSON keymaps without polluting the tree * Add support for passing environment vars to make * make flake8 happy * document changes to qmk compile and flash * add -e support to json export compiling * Fix python 3.6 * honor $MAKE * add support for parallel builds
* c2json: Fix TypeError on MSYS2 (#10709)Ryan2020-10-231-1/+2
|
* [CLI] Add c2json (#8817)Erovia2020-10-061-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Basic keymap parsing finally works * Add 'keymap.json' creation to the qmk.keymap module * Add tests and fix formatting * Fix/exclude flake8 errors * Convert keymap.c to valid keymap.json * Fix some errors * Add tests * Finalize keymap.json creation, add json template * Add docs * Move pygments to the standard requirements * Add support for nameless layers, fix tests * Fix things after rebase * Add missing 'keymap' value. * Fix missing layer numbers from advanced keycodes Buckwich noticed that if the advanced keycode / layer toggling key contains a number, it goes missing. Now we properly handle them. Thx for noticing! * Apply suggestions from code review * fixup tests Co-authored-by: Zach White <skullydazed@drpepper.org> Co-authored-by: skullY <skullydazed@gmail.com>
* Add debug logging to `run()` (#9986)Ryan2020-08-281-0/+3
|
* [CLI] Add a subcommand for getting information about a keyboard (#8666)Zach White2020-05-261-0/+1
| | | | | You can now use `qmk info` to get information about keyboards and keymaps. Co-authored-by: Erovia <Erovia@users.noreply.github.com>
* CLI: Use `shutil.which` to detect gmake, instead of OS check.Pete Johanson2020-04-131-5/+2
|
* CLI: Invoke gmake on FreeBSD when using `qmk compile`.Pete Johanson2020-04-131-1/+6
| | | | * Current makefiles aren't portable, so invoke gmake on FreeBSD.
* CLI: More MSYS2 fixes (#8577)Erovia2020-03-291-0/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * CLI: More MSYS2 fixes Now I can fully setup and work with qmk_firmware on an MSYS2 installation without any errors or exceptions. * Apply suggestions from code review Co-Authored-By: skullydazed <skullydazed@users.noreply.github.com> * Some improvements * Remove unnecessary import * Remove slow, unused code Getting the version from GIT was slow on both Windows and Docker. Until we find a better, faster way, this is removed. * remove unused imports * Implement @vomindoraan's suggestions * refine how we pick the shell to use * Apply @fauxpark's suggestions fauxpark investigated the topic of shells in MSYS2 a bit and we come to the conclusion that the safest bet was to just use the user's shell. Anything more just opens up more edge-cases than it solves. Co-Authored-By: Ryan <fauxpark@gmail.com> * Use `platform_id` in doctor This will bring it in line with the new code. Co-authored-by: skullydazed <skullydazed@users.noreply.github.com> Co-authored-by: skullY <skullydazed@gmail.com> Co-authored-by: Ryan <fauxpark@gmail.com>
* Add decorators for determining keyboard and keymap based on current ↵skullydazed2020-03-131-69/+0
| | | | | | | | | | | | | | | | | | | directory (#8191) * Use pathlib everywhere we can * Improvements based on @erovia's feedback * rework qmk compile and qmk flash to use pathlib * style * Remove the subcommand_name argument from find_keyboard_keymap() * add experimental decorators * Create decorators for finding keyboard and keymap based on current directory. Decorators were inspired by @Erovia's brilliant work on the proof of concept.
* Use pathlib everywhere we can (#7872)skullydazed2020-02-171-9/+87
| | | | | | | | | | | | | | | | | | | | | | * Use pathlib everywhere we can * Update lib/python/qmk/path.py Co-Authored-By: Erovia <Erovia@users.noreply.github.com> * Update lib/python/qmk/path.py Co-Authored-By: Erovia <Erovia@users.noreply.github.com> * Improvements based on @erovia's feedback * rework qmk compile and qmk flash to use pathlib * style * Remove the subcommand_name argument from find_keyboard_keymap() Co-authored-by: Erovia <Erovia@users.noreply.github.com>
* Fix compiling json filesZach White2019-12-081-8/+3
|
* format code according to conventions [skip ci]QMK Bot2019-11-161-1/+3
|
* Add CLI command for flashing a keyboardjorgemanzo2019-11-151-0/+57
A new CLI subcommand was added, flash, which behaves very similar to the already present compile CLI comamnd, but with the added ability to target a bootloader. The command is used like so: qmk flash [-h] [-b] [-kb KEYBOARD] [-km KEYMAP] [-bl BOOTLOADER] [filename]. A -kb <keyboard> and -km <keymap> is expected, or a configurator export JSON filename. A bootloader can be specified using -bl <target>, and if left unspecified, the target is assumed to be :flash. -bl can be used to list the available bootloaders. If -km <keymap> is provided, but no -kb <keyboard>, then a message is printed suggesting the user to run qmk list_keyboards.