This repository has no description
0

Configure Feed

Select the types of activity you want to include in your feed.

sway: use swaylock service

+11 -7
+10 -6
2configs/desktops/lib/wayland.nix
··· 47 47 48 48 security.polkit.enable = true; 49 49 security.pam.services.swaylock = { }; 50 + security.pam.services.swaylock-plugin = { }; 50 51 51 52 programs.dconf.enable = lib.mkDefault true; 52 53 services.gnome.gnome-keyring.enable = lib.mkDefault true; ··· 125 126 description = "Screen locker for Wayland"; 126 127 documentation = [ "man:swaylock(1)" ]; 127 128 129 + # Requires graphical session 130 + requisite = [ "graphical-session.target" ]; 131 + after = [ "graphical-session.target" ]; 132 + 128 133 # If swaylock exits cleanly, unlock the session: 129 134 onSuccess = [ "unlock.target" ]; 130 135 ··· 136 141 wantedBy = [ "lock.target" ]; 137 142 138 143 serviceConfig = { 139 - # systemd will consider this service started when swaylock forks... 140 - Type = "forking"; 141 - 142 - # ... and swaylock will fork only after it has locked the screen. 143 - ExecStart = "${lib.getExe pkgs.swaylock} --image /var/lib/wallpaper/wallpaper -f"; 144 - 144 + Type = "simple"; 145 145 # If swaylock crashes, always restart it immediately: 146 146 Restart = "on-failure"; 147 147 RestartSec = 0; 148 148 }; 149 + 150 + path = [ pkgs.bash ]; 151 + 152 + serviceConfig.ExecStart = lib.getExe self.packages.${pkgs.system}.lockscreen; 149 153 }; 150 154 }
+1 -1
2configs/desktops/sway/default.nix
··· 320 320 bindsym $mod+Escape workspace back_and_forth 321 321 322 322 # screenlock 323 - bindsym $mod+F11 exec ${pkgs.swaylock}/bin/swaylock -f -c 000000 323 + bindsym $mod+F11 exec ${lib.getExe' pkgs.systemd "systemctl"} --user start lock.target 324 324 325 325 # media buttons 326 326 bindsym XF86AudioMute exec ${pkgs.pulseaudio.out}/bin/pactl -- set-sink-mute @DEFAULT_SINK@ toggle