summary refs log tree commit diff
path: root/nixos/modules
diff options
context:
space:
mode:
authorWORLDofPEACE <worldofpeace@protonmail.ch>2020-09-14 20:44:51 -0400
committerGitHub <noreply@github.com>2020-09-14 20:44:51 -0400
commitd23f814eb39a8ed9935e83376e6c40c1a7793212 (patch)
tree322f60cb32a08f1a44c98939bfc5cf5b9d6ac720 /nixos/modules
parent9f68287e3d2108683ba6bc265796390031ee223d (diff)
parent0c6e1ddf61712f463fa4077339670cd940188fd3 (diff)
downloadnixpkgs-d23f814eb39a8ed9935e83376e6c40c1a7793212.tar
nixpkgs-d23f814eb39a8ed9935e83376e6c40c1a7793212.tar.gz
nixpkgs-d23f814eb39a8ed9935e83376e6c40c1a7793212.tar.bz2
nixpkgs-d23f814eb39a8ed9935e83376e6c40c1a7793212.tar.lz
nixpkgs-d23f814eb39a8ed9935e83376e6c40c1a7793212.tar.xz
nixpkgs-d23f814eb39a8ed9935e83376e6c40c1a7793212.tar.zst
nixpkgs-d23f814eb39a8ed9935e83376e6c40c1a7793212.zip
Merge pull request #98004 from romildo/upd.nm-applet
nixos/nm-applet: starts the applet with Appindicator support
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/programs/nm-applet.nix15
-rw-r--r--nixos/modules/services/x11/desktop-managers/pantheon.nix2
2 files changed, 15 insertions, 2 deletions
diff --git a/nixos/modules/programs/nm-applet.nix b/nixos/modules/programs/nm-applet.nix
index 273a6dec59a..5bcee30125b 100644
--- a/nixos/modules/programs/nm-applet.nix
+++ b/nixos/modules/programs/nm-applet.nix
@@ -5,14 +5,25 @@
     maintainers = lib.teams.freedesktop.members;
   };
 
-  options.programs.nm-applet.enable = lib.mkEnableOption "nm-applet";
+  options.programs.nm-applet = {
+    enable = lib.mkEnableOption "nm-applet";
+
+    indicator = lib.mkOption {
+      type = lib.types.bool;
+      default = true;
+      description = ''
+        Whether to use indicator instead of status icon.
+        It is needed for Appindicator environments, like Enlightenment.
+      '';
+    };
+  };
 
   config = lib.mkIf config.programs.nm-applet.enable {
     systemd.user.services.nm-applet = {
       description = "Network manager applet";
       wantedBy = [ "graphical-session.target" ];
       partOf = [ "graphical-session.target" ];
-      serviceConfig.ExecStart = "${pkgs.networkmanagerapplet}/bin/nm-applet";
+      serviceConfig.ExecStart = "${pkgs.networkmanagerapplet}/bin/nm-applet ${lib.optionalString config.programs.nm-applet.indicator "--indicator"}";
     };
 
     services.dbus.packages = [ pkgs.gcr ];
diff --git a/nixos/modules/services/x11/desktop-managers/pantheon.nix b/nixos/modules/services/x11/desktop-managers/pantheon.nix
index 6dabca6bf09..e67e216f90d 100644
--- a/nixos/modules/services/x11/desktop-managers/pantheon.nix
+++ b/nixos/modules/services/x11/desktop-managers/pantheon.nix
@@ -240,6 +240,8 @@ in
       # Otherwise you can't store NetworkManager Secrets with
       # "Store the password only for this user"
       programs.nm-applet.enable = true;
+      # Pantheon has its own network indicator
+      programs.nm-applet.indicator = false;
 
       # Shell integration for VTE terminals
       programs.bash.vteIntegration = mkDefault true;