rmkit is a toolkit set for RMK keyboard firmware.
Now rmkit can be used to generate RMK project directly from keyboard.toml and vial.json, or interactively.
-
Install rmkit:
If you have Rust installed in your machine, you can use Cargo to install rmkit
cargo install rmkit # If you have cargo-binstall, you can use it to speedup the installation: cargo binstall rmkitrmkit also provides install script that you can use:
# macOS/linux curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rmk-rs/rmkit/releases/latest/download/rmkit-installer.sh | sh # Windows(powershell) powershell -ExecutionPolicy ByPass -c "irm https://github.com/rmk-rs/rmkit/releases/latest/download/rmkit-installer.ps1 | iex"
-
Create RMK project from
keyboard.tomlandvial.json:rmkit create --keyboard-toml-path keyboard.toml --vial-json-path vial.jsonA
Cargo.tomlormemory.xnext tokeyboard.tomlreplaces the template's copy as-is — use it to add Cargo features, pin dependencies, or change the flash layout. When you provideCargo.toml, rmkit no longer adjusts thermkfeatures for you. -
Or, you can create RMK project from project template
rmkit initThe available project template can be found at rmk-template
rmkit layout works with the physical [layout] section of a keyboard.toml. The conversion engine is the rynk-kle library crate (which also compiles to a wasm package for the web); this CLI wraps it.
Convert a KLE JSON export or a Vial definition (vial.json) into RMK's [layout] — key positions, cap sizes, split gaps, rotation, ISO/L-shaped caps, encoders, and VIA layout options are all converted, and the result is validated against RMK's own layout builder. KLE carries no keycodes, so author the [keymap] yourself:
rmkit layout convert path/to/vial.json -o layout.toml # vial.json → [layout]
rmkit layout convert path/to/kle_export.json # raw KLE "Download JSON" export too
rmkit layout convert --to-vial keyboard.toml # reverse: [layout] → vial.jsonRender a physical layout as box-drawing art, to check the geometry in a terminal without flashing anything. The input can be a keyboard.toml, or a vial.json / raw KLE export directly (converted on the fly); --variant picks one [[layout.variant]]:
$ rmkit layout show keyboard.toml
variant 'default': 17 keys, 4u × 5u
┌─────┬─────┬─────┬─────┐
│ 0,0 │ 0,1 │ 0,2 │ 0,3 │
│ │ │ │ │
├─────┼─────┼─────┼─────┤
│ 1,0 │ 1,1 │ 1,2 │ │
│ │ │ │ │
├─────┼─────┼─────┤ 1,3 │
│ 2,0 │ 2,1 │ 2,2 │ │
│ │ │ │ │
├─────┼─────┼─────┼─────┤
│ 3,0 │ 3,1 │ 3,2 │ │
│ │ │ │ │
├─────┴─────┼─────┤ 3,3 │
│ 4,0 │ 4,1 │ │
│ │ │ │
└───────────┴─────┴─────┘