Testing lib.mkForce

This commit is contained in:
2026-03-01 18:14:35 +01:00
parent a503e0ec4d
commit db2b9e4a06
5 changed files with 407 additions and 459 deletions
+5 -12
View File
@@ -1,21 +1,14 @@
{ config, lib, pkgs, flakeRoot, ... }:
let
repoWaybarDir = flakeRoot + "/assets/conf/desktop/waybar";
repoWaybarDir = flakeRoot.outPath + "/assets/conf/desktop/waybar";
in
{
programs.waybar.enable = true;
# Ensure config matches repo (HM-managed symlink, not user-editable)
xdg.configFile."waybar/config" = {
source = lib.mkForce (repoWaybarDir + "/config.jsonc");
force = true;
home.file.".config/waybar/config" = {
source = repoWaybarDir + "/config.jsonc";
};
# Override HM's internally-generated waybar-style.css derivation
# and use your repo file instead.
xdg.configFile."waybar/style.css" = {
source = lib.mkForce (repoWaybarDir + "/style.css");
force = true;
home.file.".config/waybar/style.css" = {
source = repoWaybarDir + "/style.css";
};
# Prevent HM from also trying to generate style content via programs.waybar.style
# (not strictly required once mkForce is in place, but keeps intent clear)
programs.waybar.style = "";
}