1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-23 19:49:45 +01:00
home-manager/tests/modules/services/sxhkd/service.nix

29 lines
657 B
Nix
Raw Normal View History

{ config, pkgs, ... }:
2019-09-15 23:12:08 +02:00
{
config = {
xsession = {
enable = true;
windowManager.command = "";
};
2019-09-15 23:12:08 +02:00
services.sxhkd = {
enable = true;
package = pkgs.runCommandLocal "dummy-package" { } "mkdir $out" // { outPath = "@sxhkd@"; };
extraOptions = [ "-m 1" ];
2019-09-15 23:12:08 +02:00
};
nmt.script = ''
xsessionFile=home-files/.xsession
2019-09-15 23:12:08 +02:00
assertFileExists $xsessionFile
2019-09-15 23:12:08 +02:00
assertFileContains $xsessionFile \
'systemctl --user stop sxhkd.scope 2> /dev/null || true'
assertFileContains $xsessionFile \
'systemd-cat -t sxhkd systemd-run --user --scope -u sxhkd @sxhkd@/bin/sxhkd -m 1 &'
2019-09-15 23:12:08 +02:00
'';
};
}