1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-12-07 01:21:03 +01:00

screen-locker: add lockCmdEnv option (#6592)

This commit is contained in:
Marijan Petričević 2025-03-12 19:31:54 +07:00 committed by GitHub
parent c630dfa8ab
commit 5871e21c11
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 13 additions and 0 deletions

View file

@ -5,6 +5,7 @@
enable = true;
inactiveInterval = 5;
lockCmd = "${pkgs.i3lock}/bin/i3lock -n -c AA0000";
lockCmdEnv = [ "DISPLAY=:0" "XAUTHORITY=/custom/path/.Xauthority" ];
xss-lock = { extraOptions = [ "-test" ]; };
xautolock = {
enable = true;
@ -19,6 +20,8 @@
assertFileExists $xssService
assertFileRegex $xssService 'ExecStart=.*/bin/xss-lock.*-test.*i3lock -n -c AA0000'
assertFileRegex $xssService 'Environment=DISPLAY=:0'
assertFileRegex $xssService 'Environment=XAUTHORITY=/custom/path/.Xauthority'
assertFileRegex $xssService 'Restart=always'
assertFileExists $xautolockService
assertFileRegex $xautolockService 'ExecStart=.*/bin/xautolock.*-time 5.*-detectsleep.*-test.*'

View file

@ -5,6 +5,7 @@
enable = true;
inactiveInterval = 5;
lockCmd = "${pkgs.i3lock}/bin/i3lock -n -c AA0000";
lockCmdEnv = [ "DISPLAY=:0" "XAUTHORITY=/custom/path/.Xauthority" ];
xssLockExtraOptions = [ "-test" ];
xautolockExtraOptions = [ "-test" ];
enableDetectSleep = true;