home-manager @ d300a8d63146bcf6387bd76ea5723495c9b52066

Use proper portal config

To get this working a I needed to add a niri-portals.conf. Later this
will come from the niri-portalsconf package
  1diff --git a/flake.lock b/flake.lock
  2index 027ecd842a1132cef7690c101e6e21d73b68ccd9..62b66ebf6e8474f45a27b70857a51e487f973210 100644
  3--- a/flake.lock
  4+++ b/flake.lock
  5@@ -268,11 +268,11 @@       "inputs": {
  6         "systems": "systems_4"
  7       },
  8       "locked": {
  9-        "lastModified": 1710146030,
 10-        "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
 11+        "lastModified": 1731533236,
 12+        "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
 13         "owner": "numtide",
 14         "repo": "flake-utils",
 15-        "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
 16+        "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
 17         "type": "github"
 18       },
 19       "original": {
 20@@ -290,11 +290,11 @@         "zig": "zig",
 21         "zon2nix": "zon2nix"
 22       },
 23       "locked": {
 24-        "lastModified": 1750884490,
 25-        "narHash": "sha256-hRt8xWReiDFyR4MDFg7FCq1PtvJb8hmrelkifnu/7yI=",
 26+        "lastModified": 1752593456,
 27+        "narHash": "sha256-H/rJ/svNsq8Y7+jXtsOUJVRdWmmQnHXxVZe3wAo4lYo=",
 28         "ref": "refs/heads/main",
 29-        "rev": "fa47db5363bedc5c3c9add87a83427447a273a90",
 30-        "revCount": 10771,
 31+        "rev": "f44c24ef88b9a663e760ad3a5a5866eb146b051e",
 32+        "revCount": 11226,
 33         "type": "git",
 34         "url": "ssh://git@github.com/ghostty-org/ghostty"
 35       },
 36@@ -412,11 +412,11 @@         "flake-utils": "flake-utils_2",
 37         "nixpkgs": "nixpkgs_10"
 38       },
 39       "locked": {
 40-        "lastModified": 1750671555,
 41-        "narHash": "sha256-6G/tp3vkZD5KTdOOcUeDMqckSD4sBqXN2hCIW08LPrs=",
 42+        "lastModified": 1752481954,
 43+        "narHash": "sha256-/PDplX/0EuhmjiQsksXLIq8D5t2QuOd8Tw8A9tLG0WE=",
 44         "ref": "refs/heads/develop",
 45-        "rev": "fd165d11ac6c3b48870588641c282e0b3aad16d8",
 46-        "revCount": 724,
 47+        "rev": "7a4031725331435c1fe2a452c57608d9d03c3968",
 48+        "revCount": 730,
 49         "type": "git",
 50         "url": "ssh://git@github.com/grid-x/gxctl"
 51       },
 52@@ -432,11 +432,11 @@           "nixpkgs"
 53         ]
 54       },
 55       "locked": {
 56-        "lastModified": 1750798083,
 57-        "narHash": "sha256-DTCCcp6WCFaYXWKFRA6fiI2zlvOLCf5Vwx8+/0R8Wc4=",
 58+        "lastModified": 1752603129,
 59+        "narHash": "sha256-S+wmHhwNQ5Ru689L2Gu8n1OD6s9eU9n9mD827JNR+kw=",
 60         "owner": "nix-community",
 61         "repo": "home-manager",
 62-        "rev": "ff31a4677c1a8ae506aa7e003a3dba08cb203f82",
 63+        "rev": "e8c19a3cec2814c754f031ab3ae7316b64da085b",
 64         "type": "github"
 65       },
 66       "original": {
 67@@ -573,27 +573,27 @@       }
 68     },
 69     "nixpkgs_10": {
 70       "locked": {
 71-        "lastModified": 1720691131,
 72-        "narHash": "sha256-CWT+KN8aTPyMIx8P303gsVxUnkinIz0a/Cmasz1jyIM=",
 73+        "lastModified": 1751943650,
 74+        "narHash": "sha256-7orTnNqkGGru8Je6Un6mq1T8YVVU/O5kyW4+f9C1mZQ=",
 75         "owner": "NixOS",
 76         "repo": "nixpkgs",
 77-        "rev": "a046c1202e11b62cbede5385ba64908feb7bfac4",
 78+        "rev": "88983d4b665fb491861005137ce2b11a9f89f203",
 79         "type": "github"
 80       },
 81       "original": {
 82         "owner": "NixOS",
 83-        "ref": "nixos-24.05",
 84+        "ref": "nixos-25.05",
 85         "repo": "nixpkgs",
 86         "type": "github"
 87       }
 88     },
 89     "nixpkgs_11": {
 90       "locked": {
 91-        "lastModified": 1750776420,
 92-        "narHash": "sha256-/CG+w0o0oJ5itVklOoLbdn2dGB0wbZVOoDm4np6w09A=",
 93+        "lastModified": 1752480373,
 94+        "narHash": "sha256-JHQbm+OcGp32wAsXTE/FLYGNpb+4GLi5oTvCxwSoBOA=",
 95         "owner": "nixos",
 96         "repo": "nixpkgs",
 97-        "rev": "30a61f056ac492e3b7cdcb69c1e6abdcf00e39cf",
 98+        "rev": "62e0f05ede1da0d54515d4ea8ce9c733f12d9f08",
 99         "type": "github"
100       },
101       "original": {
102@@ -800,7 +800,8 @@     },
103     "zig": {
104       "inputs": {
105         "flake-compat": [
106-          "ghostty"
107+          "ghostty",
108+          "flake-compat"
109         ],
110         "flake-utils": [
111           "ghostty",
112@@ -846,8 +847,8 @@         "type": "github"
113       },
114       "original": {
115         "owner": "jcollie",
116-        "ref": "56c159be489cc6c0e73c3930bd908ddc6fe89613",
117         "repo": "zon2nix",
118+        "rev": "56c159be489cc6c0e73c3930bd908ddc6fe89613",
119         "type": "github"
120       }
121     }
122diff --git a/mako.nix b/mako.nix
123index 74a51ff0ef4680540427089c081546abbcaaaf8e..bacc2bb0f395f65cd340fcd8467029c820a10b48 100644
124--- a/mako.nix
125+++ b/mako.nix
126@@ -7,7 +7,6 @@   xdg.configFile."mako/config".text = ''
127     border-size=0
128     font=monospace 14
129     default-timeout=15000
130-    on-notify=exec mpv /usr/share/sounds/freedesktop/stereo/message.oga
131 
132     [urgency=high]
133     background-color=#bf616a
134diff --git a/niri.nix b/niri.nix
135index ad0f93989d823046d3b709fd0738aa8fe82f34a4..feeb14db1d02c4c95286b10acbe1b6b7f3d1b869 100644
136--- a/niri.nix
137+++ b/niri.nix
138@@ -60,9 +60,8 @@     overview {
139         backdrop-color "#DDDDDD"
140     }
141 
142-    spawn-at-startup "dbus-update-activation-environment" "WAYLAND_DISPLAY" "XDG_CURRENT_DESKTOP=sway"
143-    spawn-at-startup "/usr/libexec/pipewire-launcher"
144-    //spawn-at-startup "openrc --user gui"
145+    spawn-at-startup "dbus-update-activation-environment" "WAYLAND_DISPLAY" "XDG_CURRENT_DESKTOP=niri"
146+    spawn-at-startup "openrc" "--user" "gui"
147 
148     spawn-at-startup "blueman-applet"
149     spawn-at-startup "mako"
150@@ -154,6 +153,10 @@         Mod+Shift+WheelScrollDown      { focus-column-right; }
151         Mod+Shift+WheelScrollUp        { focus-column-left; }
152         Mod+Ctrl+Shift+WheelScrollDown { move-column-right; }
153         Mod+Ctrl+Shift+WheelScrollUp   { move-column-left; }
154+
155+        Mod+S { set-dynamic-cast-window; }
156+        Mod+Shift+S { set-dynamic-cast-monitor; }
157+        Mod+Ctrl+S { clear-dynamic-cast-target; }
158 
159         Mod+1 { focus-workspace "α"; }
160         Mod+2 { focus-workspace "γ"; }
161@@ -258,6 +261,12 @@         block-out-from "screencast"
162     }
163 
164     window-rule {
165+        match app-id=r#"^firefox$"#
166+
167+        block-out-from "screencast"
168+    }
169+
170+    window-rule {
171         match app-id=r#"^Bitwarden$"#
172 
173         open-on-workspace "res"
174@@ -274,9 +283,36 @@     }
175 
176 
177     layer-rule {
178-        exclude namespace="^notifications$"
179+        match namespace="^notifications$"
180+        block-out-from "screencast"
181+    }
182 
183+    layer-rule {
184+        match namespace="^waybar$"
185         block-out-from "screencast"
186+    }
187+
188+
189+    window-rule {
190+        match is-window-cast-target=true
191+
192+        focus-ring {
193+            active-color "#f38ba8"
194+            inactive-color "#7d0d2d"
195+        }
196+
197+        border {
198+            inactive-color "#7d0d2d"
199+        }
200+
201+        shadow {
202+            color "#7d0d2d70"
203+        }
204+
205+        tab-indicator {
206+            active-color "#f38ba8"
207+            inactive-color "#7d0d2d"
208+        }
209     }
210 
211     // user private to hide private browser
212diff --git a/profile.nix b/profile.nix
213index e48cb8f0bcc3aba91963c3cd0a51962f0ea7fabe..520ad831702e238f6a35ebbb9d6ae2df29998e55 100644
214--- a/profile.nix
215+++ b/profile.nix
216@@ -22,6 +22,7 @@     export EDITOR=nvim
217     export BROWSER=/usr/bin/qutebrowser
218     export PATH=$PATH:$HOME/.local/bin/
219     export QT_QPA_PLATFORM=wayland
220+    export XDG_CURRENT_DESKTOP=niri
221 
222     # GO
223     export GOPATH=$XDG_DATA_HOME/go
224@@ -63,7 +64,6 @@     export PATH=$PATH:$HOME/.nix-profile/bin/
225 
226     if [[ "$(tty)" == "/dev/tty1" ]]
227     then
228-
229         eval `ssh-agent`
230 
231         if command -v niri 2>&1 >/dev/null