mirror of
https://github.com/nix-community/home-manager.git
synced 2026-11-03 11:20:14 +00:00
Keep application settings writable while applying declared values. Restore unchanged immutable links through the shared helper and keep private-key management explicit.
24 lines
674 B
Nix
24 lines
674 B
Nix
{ config, pkgs, ... }:
|
|
{
|
|
xdg.configHome = "${config.home.homeDirectory}/custom-config";
|
|
programs.algia = {
|
|
enable = true;
|
|
mutableSettings = false;
|
|
};
|
|
assertions = [
|
|
{
|
|
assertion = !(config.home.activation ? algiaMutableSettings);
|
|
message = "Inactive algia settings must not create mutable activation.";
|
|
}
|
|
{
|
|
assertion = !(config.home.activation ? algiaImmutableSettings);
|
|
message = "Inactive algia settings must not create immutable cleanup.";
|
|
}
|
|
];
|
|
nmt.script = ''
|
|
assertPathNotExists "home-files/${
|
|
if pkgs.stdenv.hostPlatform.isDarwin then ".config" else "custom-config"
|
|
}/algia/config.json"
|
|
'';
|
|
}
|