Skip to content

Commit

Permalink
refactor(home): move swaylock to module
Browse files Browse the repository at this point in the history
  • Loading branch information
nevivurn committed Jul 15, 2024
1 parent d5dbc6b commit 9c13db5
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 9 deletions.
6 changes: 3 additions & 3 deletions home/profiles/sway/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -464,15 +464,15 @@ in
enable = true;
events =
let
swaylock = config.programs.swaylock.package;
swaylock = lib.getExe config.programs.swaylock.package;
in
[
{
command = "${swaylock}/bin/swaylock -f";
command = "${swaylock} -f";
event = "lock";
}
{
command = "${swaylock}/bin/swaylock -f";
command = "${swaylock} -f";
event = "before-sleep";
}
];
Expand Down
3 changes: 3 additions & 0 deletions nixos/profiles/graphical/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
services.pipewire.enable = true;
services.pipewire.pulse.enable = true;

# swaylock locks out otherwise
security.pam.services.swaylock = { };

hardware.bluetooth = {
enable = true;
settings = {
Expand Down
3 changes: 0 additions & 3 deletions systems/taiyi/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -147,9 +147,6 @@ in

## Other hardware-specific configuration

# swaylock locks out otherwise
security.pam.services.swaylock = { };

# podman requires system-level config
virtualisation.podman = {
enable = true;
Expand Down
3 changes: 0 additions & 3 deletions systems/tianyi/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -250,9 +250,6 @@ in
services.xserver.xkb.options = "ctrl:swapcaps,korean:ralt_hangul";
console.useXkbConfig = true;

# swaylock locks out otherwise
security.pam.services.swaylock = { };

# podman requires system-level config
virtualisation.podman = {
enable = true;
Expand Down

0 comments on commit 9c13db5

Please sign in to comment.