Commit 5f3737b9c5cc

Vincent Demeester <vincent@sbr.pm>
2026-11-10 13:24:29
fix(niri): added Fedora mako user service
Added the missing unit so D-Bus can activate desktop notifications. Signed-off-by: Vincent Demeester <vincent@sbr.pm>
1 parent 2eb48c1
Changed files (1)
home
common
desktop
home/common/desktop/niri/default.nix
@@ -1,4 +1,9 @@
-{ pkgs, ... }:
+{
+  lib,
+  osConfig ? null,
+  pkgs,
+  ...
+}:
 {
   imports = [
     ../sway/kanshi.nix
@@ -35,6 +40,22 @@
     kunai
   ];
 
+  # On NixOS, the system profile exposes mako.service. Fedora user systemd
+  # does not search the Nix profile's unit directory, even though D-Bus finds
+  # Mako's activator, so install and start the unit through Home Manager.
+  systemd.user.services.mako = lib.mkIf (osConfig == null) {
+    Unit = {
+      Description = "Lightweight Wayland notification daemon";
+      PartOf = [ "graphical-session.target" ];
+      After = [ "graphical-session.target" ];
+    };
+    Service = {
+      ExecStart = "${pkgs.mako}/bin/mako";
+      Restart = "on-failure";
+    };
+    Install.WantedBy = [ "graphical-session.target" ];
+  };
+
   services = {
     avizo.enable = true;
     wlsunset = {