Document 'make all:<name>' (#8439)

* Document 'make all:<name>'

* add cli docs

* Apply suggestions from code review

Co-Authored-By: skullydazed <skullydazed@users.noreply.github.com>

Co-authored-by: skullydazed <skullydazed@users.noreply.github.com>
This commit is contained in:
Joel Challis 2020-03-16 14:27:19 +00:00 committed by GitHub
parent c89012566c
commit 19dbcf3814
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 22 additions and 4 deletions

View file

@ -57,6 +57,12 @@ Must be in keyboard directory with a default keymap, or in keymap directory for
qmk compile
```
**Usage for building all keyboards that support a specific keymap**:
```
qmk compile -kb all -km <keymap_name>
```
**Example**:
```
$ qmk config compile.keymap=default

View file

@ -97,13 +97,25 @@ You'd want to replace the year, name, email and github username with your info.
Additionally, this is a good place to document your code, if you wish to share it with others.
# Examples
## Build All Keyboards That Support a Specific Keymap
Want to check all your keymaps build in a single command? You can run:
make all:<name>
For example,
make all:jack
This is ideal for when you want ensure everything compiles successfully when preparing a [_Pull request_](https://github.com/qmk/qmk_firmware/pulls).
## Examples
For a brief example, checkout [`/users/_example/`](https://github.com/qmk/qmk_firmware/tree/master/users/drashna).
For a more complicated example, checkout [`/users/drashna/`](https://github.com/qmk/qmk_firmware/tree/master/users/drashna)'s userspace.
## Customized Functions
### Customized Functions
QMK has a bunch of [functions](custom_quantum_functions.md) that have [`_quantum`, `_kb`, and `_user` versions](custom_quantum_functions.md#a-word-on-core-vs-keyboards-vs-keymap) that you can use. You will pretty much always want to use the user version of these functions. But the problem is that if you use them in your userspace, then you don't have a version that you can use in your keymap.
@ -130,7 +142,7 @@ The `_keymap` part here doesn't matter, it just needs to be something other than
You can see a list of this and other common functions in [`template.c`](https://github.com/qmk/qmk_firmware/blob/master/users/drashna/template.c) in [`users/drashna`](https://github.com/qmk/qmk_firmware/tree/master/users/drashna).
## Custom Features
### Custom Features
Since the Userspace feature can support a staggering number of boards, you may have boards that you want to enable certain functionality for, but not for others. And you can actually create "features" that you can enable or disable in your own userspace.
@ -166,7 +178,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
```
## Consolidated Macros
### Consolidated Macros
If you wanted to consolidate macros and other functions into your userspace for all of your keymaps, you can do that. This builds upon the [Customized Functions](#customized-functions) example above. This lets you maintain a bunch of macros that are shared between the different keyboards, and allow for keyboard specific macros, too.