mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-01-21 15:11:34 +01:00
Wrap hyprlock
This commit is contained in:
parent
08dae72f8d
commit
e7fbcb4a49
5 changed files with 28 additions and 105 deletions
|
|
@ -1,33 +1,19 @@
|
|||
{
|
||||
inputs,
|
||||
config,
|
||||
lib,
|
||||
wrappers,
|
||||
...
|
||||
}: {
|
||||
imports = [inputs.hyprlock.homeManagerModules.hyprlock];
|
||||
|
||||
options.myConfig.de.hypridlelock.enable = lib.mkEnableOption "";
|
||||
|
||||
config = lib.mkIf config.myConfig.de.hypridlelock.enable {
|
||||
programs.hyprlock = {
|
||||
enable = true;
|
||||
|
||||
backgrounds = [
|
||||
{
|
||||
path = "screenshot";
|
||||
blur_passes = 1;
|
||||
blur_size = 4;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
services.hypridle = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
general = {
|
||||
lock_cmd = let
|
||||
hyprlockExe = "${lib.getExe config.programs.hyprlock.package}";
|
||||
hyprlockExe = "${lib.getExe wrappers.hyprlock}";
|
||||
in "pidof ${hyprlockExe} || ${hyprlockExe}";
|
||||
before_sleep_cmd = "loginctl lock-session";
|
||||
after_sleep_cmd = "hyprctl dispatch dpms on";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue