nix/home/file/keyd/module/Disable.nix

30 lines
477 B
Nix
Raw Normal View History

{ pkgs, ... }:
let
apps = [
"gimp"
"gimp-*"
"steam-proton"
"steam-app-*"
];
2024-11-04 04:37:29 +03:00
keys = [
"escape"
"leftcontrol"
];
in
{
file =
let
keySets = builtins.map (key: {
name = key;
value = key;
}) keys;
2024-11-04 04:37:29 +03:00
appSets = builtins.map (app: {
name = app;
value = builtins.listToAttrs keySets;
}) apps;
in
2024-12-21 13:45:27 +03:00
(pkgs.formats.ini { }).generate "keyd-disable-config" (builtins.listToAttrs appSets);
}