fix(menu): force-own networkmanager-dmenu config.ini

networkmanager_dmenu writes a default config on first run, so an
unmanaged file can already sit at ~/.config/networkmanager-dmenu/
config.ini and abort `home-manager switch` with a clobber error. We
fully generate this file, so set force = true to overwrite it.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-06-20 18:27:35 +01:00
parent 0c483f9512
commit 97b5944dc1

View File

@@ -421,8 +421,12 @@ in
# networkmanager_dmenu drives rofi (not bare dmenu) and uses rofi's # networkmanager_dmenu drives rofi (not bare dmenu) and uses rofi's
# active/urgent row styling for the connected/available networks, so it # active/urgent row styling for the connected/available networks, so it
# inherits the generated theme like every other menu module. Editing a # inherits the generated theme like every other menu module. Editing a
# connection drops to nmtui in the configured terminal. # connection drops to nmtui in the configured terminal. force: the tool
xdg.configFile."networkmanager-dmenu/config.ini".text = '' # writes a default config on first run, so an unmanaged file may already
# sit at this path — we fully own it, so overwrite rather than abort.
xdg.configFile."networkmanager-dmenu/config.ini" = {
force = true;
text = ''
[dmenu] [dmenu]
dmenu_command = rofi dmenu_command = rofi
rofi_highlight = True rofi_highlight = True
@@ -433,6 +437,7 @@ in
terminal = ${cfg.terminal} terminal = ${cfg.terminal}
gui_if_available = False gui_if_available = False
''; '';
};
programs.rofi = { programs.rofi = {
enable = true; enable = true;