1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2024-12-15 17:51:01 +00:00
nix-darwin/tests/services-skhd.nix
2018-03-05 21:41:52 +01:00

22 lines
607 B
Nix

{ config, lib, pkgs, ... }:
with lib;
let
skhd = pkgs.runCommand "skhd-0.0.0" {} "mkdir $out";
in
{
services.skhd.enable = true;
services.skhd.package = skhd;
services.skhd.skhdConfig = "alt + shift - r : chunkc quit";
test = ''
echo >&2 "checking skhd service in ~/Library/LaunchAgents"
grep "org.nixos.skhd" ${config.out}/user/Library/LaunchAgents/org.nixos.skhd.plist
grep "${skhd}/bin/skhd" ${config.out}/user/Library/LaunchAgents/org.nixos.skhd.plist
echo >&2 "checking config in /etc/skhdrc"
grep "alt + shift - r : chunkc quit" ${config.out}/etc/skhdrc
'';
}