diff options
author | Florian Klink <flokli@flokli.de> | 2024-11-14T23·31+0200 |
---|---|---|
committer | clbot <clbot@tvl.fyi> | 2024-11-15T00·00+0000 |
commit | c4459708697a85475a8ed4d03afdac565486c720 (patch) | |
tree | bff81656b30a620252b3fba94d0abf456dd9afbb /users/flokli/keyboards/chocofi/default.nix | |
parent | 7a54360a39f4c5649a48fc6be919085170c4294c (diff) |
feat(users/flokli/kb): add chocofi r/8922
`buildSplitKeyboard`, as well as all the patching of `miryoku_zmk` is independent of the specific keyboard used, so it can be moved one layer up. `config-flat` is now provided through a helper function, accepting the name of the keymap to use when rendering the config. This all makes the amount of code added for the new keyboard itself pleasantly small. Change-Id: I2216aa246502eddaf9bc4f4d126b0639d574ad87 Reviewed-on: https://cl.tvl.fyi/c/depot/+/12787 Reviewed-by: flokli <flokli@flokli.de> Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
Diffstat (limited to 'users/flokli/keyboards/chocofi/default.nix')
-rw-r--r-- | users/flokli/keyboards/chocofi/default.nix | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/users/flokli/keyboards/chocofi/default.nix b/users/flokli/keyboards/chocofi/default.nix new file mode 100644 index 000000000000..b8343f9592cc --- /dev/null +++ b/users/flokli/keyboards/chocofi/default.nix @@ -0,0 +1,25 @@ +{ pkgs, depot, ... }: +rec { + firmware = depot.users.flokli.keyboards.buildSplitKeyboard { + name = "nice_nano_v2"; + board = "nice_nano_v2"; + shield = "corne_%PART% nice_view_adapter nice_view"; + zephyrDepsHash = "sha256-D5CAlrO/E6DPbtUJyh/ec8ACpo1XM1jx2gLS2TpklBQ="; + src = depot.users.flokli.keyboards.miryoku_config; + }; + + config-flat = depot.users.flokli.keyboards.mkFlatConfig "corne"; + + flash-left = pkgs.writeShellScript "flash.sh" '' + cp ${firmware}/zmk_left.uf2 /run/media/$USER/NICENANO/ + ''; + + flash-right = pkgs.writeShellScript "flash.sh" '' + cp ${firmware}/zmk_right.uf2 /run/media/$USER/NICENANO/ + ''; + + meta.ci.targets = [ + "config-flat" + "firmware" + ]; +} |