replace swaylock with nova-shell lock
This commit is contained in:
parent
3c8024045e
commit
4c82ecd2b9
5 changed files with 42 additions and 42 deletions
8
flake.lock
generated
8
flake.lock
generated
|
|
@ -548,11 +548,11 @@
|
||||||
"treefmt-nix": "treefmt-nix"
|
"treefmt-nix": "treefmt-nix"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1776366610,
|
"lastModified": 1776422982,
|
||||||
"narHash": "sha256-7HXk7GwK7fCiIQ3ep8SsKUkfWhOOWxARuBKRPqWy0fc=",
|
"narHash": "sha256-H4TfZRvGyWHzY/o0JiSYj/0UOxLv4mOM38xQKUKFW6Q=",
|
||||||
"ref": "refs/heads/main",
|
"ref": "refs/heads/main",
|
||||||
"rev": "434f8f8ffd3801cfeac82f6caaf1b58ef25e9c11",
|
"rev": "1a78b5808d49131aa13371235172f31587f4af3f",
|
||||||
"revCount": 344,
|
"revCount": 398,
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://git.berlin.ccc.de/vinzenz/nova-shell"
|
"url": "https://git.berlin.ccc.de/vinzenz/nova-shell"
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,8 @@
|
||||||
./podman.nix
|
./podman.nix
|
||||||
./ssh.nix
|
./ssh.nix
|
||||||
./starship.nix
|
./starship.nix
|
||||||
./swaylock.nix
|
./swayidle.nix
|
||||||
|
#./swaylock.nix
|
||||||
#./swaync.nix
|
#./swaync.nix
|
||||||
./vscode.nix
|
./vscode.nix
|
||||||
# ./waybar.nix
|
# ./waybar.nix
|
||||||
|
|
@ -52,8 +53,10 @@
|
||||||
nova-shell = {
|
nova-shell = {
|
||||||
enable = true;
|
enable = true;
|
||||||
theme = {
|
theme = {
|
||||||
fontSize = 13;
|
fontSize = 14;
|
||||||
};
|
};
|
||||||
|
#modules.backgroundOverlay.enable = false;
|
||||||
|
#modules.screenCorners.enable = false;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -402,6 +402,11 @@
|
||||||
|
|
||||||
"Mod+W".action.toggle-column-tabbed-display = { };
|
"Mod+W".action.toggle-column-tabbed-display = { };
|
||||||
"Mod+O".action.toggle-overview = { };
|
"Mod+O".action.toggle-overview = { };
|
||||||
|
|
||||||
|
"Super+Alt+L" = {
|
||||||
|
action.spawn = "${pkgs.systemd}/bin/loginctl lock-session";
|
||||||
|
allow-when-locked = true;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
27
homeConfigurations/muede/swayidle.nix
Normal file
27
homeConfigurations/muede/swayidle.nix
Normal file
|
|
@ -0,0 +1,27 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
services.swayidle =
|
||||||
|
let
|
||||||
|
lock-command = "${pkgs.systemd}/bin/loginctl lock-session";
|
||||||
|
in
|
||||||
|
{
|
||||||
|
enable = true;
|
||||||
|
systemdTarget = "graphical-session.target";
|
||||||
|
timeouts = [
|
||||||
|
{
|
||||||
|
timeout = 30;
|
||||||
|
command = lock-command;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
timeout = 60 * 10;
|
||||||
|
command = "${pkgs.systemd}/bin/systemctl suspend";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
events = [
|
||||||
|
{
|
||||||
|
event = "before-sleep";
|
||||||
|
command = "${pkgs.playerctl}/bin/playerctl pause; ${lock-command}";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -1,10 +1,5 @@
|
||||||
# based on https://codeberg.org/kiara/cfg/src/commit/b9c472acd78c9c08dfe8b6a643c5c82cc5828433/home-manager/kiara/swaylock.nix#
|
# based on https://codeberg.org/kiara/cfg/src/commit/b9c472acd78c9c08dfe8b6a643c5c82cc5828433/home-manager/kiara/swaylock.nix#
|
||||||
{
|
{ pkgs, ... }:
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
{
|
||||||
stylix.targets.swaylock = {
|
stylix.targets.swaylock = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
@ -30,34 +25,4 @@
|
||||||
indicator-thickness = 20;
|
indicator-thickness = 20;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
services.swayidle = {
|
|
||||||
enable = true;
|
|
||||||
systemdTarget = "graphical-session.target";
|
|
||||||
timeouts = [
|
|
||||||
{
|
|
||||||
timeout = 5;
|
|
||||||
command = "${config.programs.swaylock.package}/bin/swaylock";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
timeout = 60 * 10;
|
|
||||||
command = "${pkgs.systemd}/bin/systemctl suspend";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
events = [
|
|
||||||
{
|
|
||||||
event = "before-sleep";
|
|
||||||
command = "${pkgs.playerctl}/bin/playerctl pause; ${config.programs.swaylock.package}/bin/swaylock";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
event = "lock";
|
|
||||||
command = "${config.programs.swaylock.package}/bin/swaylock";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.niri.settings.binds."Super+Alt+L" = {
|
|
||||||
action.spawn = "${lib.getBin config.programs.swaylock.package}/bin/swaylock";
|
|
||||||
allow-when-locked = true;
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue