feat(hyprland): emit compositor config as lua
This commit is contained in:
1 parent
4908c4751f
commit
fce4bdc526
9 files changed
+346
-119
No files matched your search
@@ -6,6 +6,16 @@
|
||||
}:
|
||||
# Clipboard history: cliphist records every copy, picked back through rofi.
|
||||
let
|
||||
execBind = key: command: {
|
||||
_args = [
|
||||
key
|
||||
(luaCall "hl.dsp.exec_cmd" [ command ])
|
||||
];
|
||||
};
|
||||
luaCall =
|
||||
function: args:
|
||||
lib.generators.mkLuaInline "${function}(${lib.concatMapStringsSep ", " toLua args})";
|
||||
|
||||
user = config.user.name;
|
||||
|
||||
cliphist = "${pkgs.cliphist}/bin/cliphist";
|
||||
@@ -22,6 +32,8 @@ let
|
||||
| ${cliphist} decode \
|
||||
| ${wl-copy}
|
||||
'';
|
||||
|
||||
toLua = lib.generators.toLua { };
|
||||
in
|
||||
{
|
||||
options.modules.desktop.utilities.clipboard.enable =
|
||||
@@ -39,9 +51,8 @@ in
|
||||
# session so uwsm starts and stops them with it.
|
||||
services.cliphist.enable = true;
|
||||
|
||||
# $mod is defined by the compositor config these binds share.
|
||||
wayland.windowManager.hyprland.settings.bind = [
|
||||
"$mod SHIFT, V, exec, ${picker}"
|
||||
(execBind "SUPER + SHIFT + V" "${picker}")
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user