1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-12-25 03:09:47 +01:00

hyprland: do not override existing plugins settings in config

The plugin setting in the Hyprland config is used both for defining
plugin paths and configuring the plugins. This fix removes the
silent override of the plugins settings converting them to the
`plugin:<name> { ...settings }` syntax.
This commit is contained in:
Samuele Facenda 2024-01-19 11:27:00 +01:00 committed by Mikilio
parent 8273de29d7
commit 3b678fe158
No known key found for this signature in database
GPG key ID: 5B2F1A890CF33F3F
3 changed files with 16 additions and 1 deletions

View file

@ -207,7 +207,8 @@ in {
else
entry;
in map mkEntry cfg.plugins;
};
} // lib.mapAttrs' (n: v: lib.nameValuePair "plugin:${n}" v)
(lib.attrByPath [ "plugin" ] { } cfg.settings);
shouldGenerate = cfg.systemd.enable || cfg.extraConfig != ""
|| combinedSettings != { };

View file

@ -26,6 +26,13 @@ input {
follow_mouse=1
kb_layout=ro
}
plugin:plugin1 {
section {
other=dummy setting
}
dummy=plugin setting
}
bindm=$mod, mouse:272, movewindow
bindm=$mod, mouse:273, resizewindow
bindm=$mod ALT, mouse:272, resizewindow

View file

@ -45,6 +45,13 @@
"$mod, mouse:273, resizewindow"
"$mod ALT, mouse:272, resizewindow"
];
plugin = {
plugin1 = {
dummy = "plugin setting";
section = { other = "dummy setting"; };
};
};
};
extraConfig = ''
# window resize