1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-18 03:30:45 +00:00

waybar: the systemd unit is coming from the package now

This commit is contained in:
r-vdp 2024-09-10 12:58:10 +02:00
parent 57077bc434
commit a03d5e6f56
No known key found for this signature in database

View file

@ -1,4 +1,9 @@
{ lib, pkgs, config, ... }:
{
lib,
pkgs,
config,
...
}:
let
cfg = config.programs.waybar;
@ -11,11 +16,9 @@ in
config = lib.mkIf cfg.enable {
environment.systemPackages = [ cfg.package ];
systemd.user.services.waybar = {
description = "Waybar as systemd service";
wantedBy = [ "graphical-session.target" ];
partOf = [ "graphical-session.target" ];
script = "${cfg.package}/bin/waybar";
systemd = {
packages = [ cfg.package ];
user.services.waybar.wantedBy = [ "graphical-session.target" ];
};
};