mirror of
https://github.com/nix-community/home-manager
synced 2024-11-30 06:59:45 +01:00
network-manager-applet: use xsession.preferStatusNotifierItems
This commit is contained in:
parent
6ae2d74fca
commit
a5a49c350d
1 changed files with 13 additions and 2 deletions
|
@ -2,6 +2,12 @@
|
||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
|
|
||||||
|
let
|
||||||
|
|
||||||
|
cfg = config.services.network-manager-applet;
|
||||||
|
|
||||||
|
in
|
||||||
|
|
||||||
{
|
{
|
||||||
meta.maintainers = [ maintainers.rycee ];
|
meta.maintainers = [ maintainers.rycee ];
|
||||||
|
|
||||||
|
@ -11,7 +17,7 @@ with lib;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf config.services.network-manager-applet.enable {
|
config = mkIf cfg.enable {
|
||||||
systemd.user.services.network-manager-applet = {
|
systemd.user.services.network-manager-applet = {
|
||||||
Unit = {
|
Unit = {
|
||||||
Description = "Network Manager applet";
|
Description = "Network Manager applet";
|
||||||
|
@ -24,7 +30,12 @@ with lib;
|
||||||
};
|
};
|
||||||
|
|
||||||
Service = {
|
Service = {
|
||||||
ExecStart = "${pkgs.networkmanagerapplet}/bin/nm-applet --sm-disable";
|
ExecStart = toString (
|
||||||
|
[
|
||||||
|
"${pkgs.networkmanagerapplet}/bin/nm-applet"
|
||||||
|
"--sm-disable"
|
||||||
|
] ++ optional config.xsession.preferStatusNotifierItems "--indicator"
|
||||||
|
);
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue