mirror of
https://github.com/nix-community/home-manager.git
synced 2026-12-06 04:40:17 +00:00
Keep user settings and marketplace registrations writable while applying declared values. Seed required marketplace metadata only where missing, preserving saved timestamps and update flags. Retain the immutable default.
26 lines
672 B
Nix
26 lines
672 B
Nix
{ config, ... }:
|
|
{
|
|
programs.claude-code = {
|
|
enable = false;
|
|
package = null;
|
|
mutableSettings = true;
|
|
settings.theme = "dark";
|
|
};
|
|
|
|
assertions = [
|
|
{
|
|
assertion = config.programs.claude-code.mutableSettings;
|
|
message = "Mutable Claude Code settings must remain enabled while the module is disabled.";
|
|
}
|
|
{
|
|
assertion = !(config.home.activation ? claudeCodeSettings);
|
|
message = "Disabled Claude Code must not register mutable settings activation.";
|
|
}
|
|
];
|
|
|
|
nmt.script = ''
|
|
assertPathNotExists "home-files/.claude/settings.json"
|
|
assertPathNotExists "home-files/.claude/plugins/known_marketplaces.json"
|
|
'';
|
|
}
|