new wallpaperthingie

This commit is contained in:
2026-03-17 18:05:34 +00:00
parent 32eafdb4d8
commit bdc3d72f91
@@ -19,24 +19,31 @@ in
};
config = lib.mkIf config.wallpaper.enable {
# Ensure the script is executable
home-manager.users.${config.home.username}.home.file."${script_path}".executable = true;
# Run the script on activation
home-manager.users.${config.home.username}.home.activation.copy-wallpapers.script = ''
echo "=== Activation Script Running ==="
echo "Script path: ${script_path}"
if [ -f "${script_path}" ]; then
echo "Script exists, executing..."
"${script_path}"
else
echo "ERROR: Script does not exist at ${script_path}"
exit 1
fi
'';
home-manager.users.${config.home.username}.home.activation.copy-wallpapers = {
description = "Copy wallpapers and set up wpaperd";
script = ''
echo "=== Activation Script Running ==="
echo "Script path: ${script_path}"
if [ -f "${script_path}" ]; then
echo "Script exists, executing..."
chmod +x "${script_path}"
"${script_path}"
else
echo "ERROR: Script does not exist at ${script_path}"
exit 1
fi
'';
};
# Install wpaperd
home-manager.users.${config.home.username}.home.packages = with pkgs; [ wpaperd ];
# Configure wpaperd using home.file
home-manager.users.${config.home.username}.home.file.".config/wpaperd/config.toml".text =
# Create the config directory and file for wpaperd
home-manager.users.${config.home.username}.xdg.configFile."wpaperd/config.toml".text =
builtins.readFile "${wallpaper_conf}";
};
}