mirror of
https://github.com/NotAShelf/batmon.git
synced 2025-01-19 00:12:40 +00:00
nix: fix package singleton
This commit is contained in:
parent
53d59bcd24
commit
957d52b64e
1 changed files with 7 additions and 4 deletions
|
@ -37,11 +37,14 @@ in {
|
|||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
systemd.user.services."batmon" = {
|
||||
description = "Power Monitoring Service";
|
||||
environment.systemPackages = [cfg.package];
|
||||
systemd.user.services.batmon = {
|
||||
description = "Simple, reactive power management service";
|
||||
documentation = "https://github.com/NotAShelf/batmon";
|
||||
wants = ["power-profiles-daemon.service"];
|
||||
wantedBy = ["default.target"];
|
||||
environment.PATH = mkForce "/run/wrappers/bin:${lib.makeBinPath cfg.package}";
|
||||
requires = ["power-profiles-daemon.service"];
|
||||
wantedBy = ["multi-user.target"];
|
||||
environment.PATH = mkForce "/run/wrappers/bin:${lib.makeBinPath [cfg.package]}";
|
||||
script = ''
|
||||
${lib.getExe cfg.package} --config ${builtins.toJSON cfg.settings}
|
||||
'';
|
||||
|
|
Loading…
Reference in a new issue