1
0
mirror of https://github.com/nix-community/home-manager synced 2024-06-28 17:38:33 +02:00

ripgrep: don't set env. variable if no config (#4254)

Fixes https://github.com/nix-community/home-manager/issues/4253
This commit is contained in:
Naïm Favier 2023-07-19 18:18:40 +02:00 committed by GitHub
parent 7579044149
commit 0841242b94
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -30,13 +30,13 @@ in {
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
home = { home = mkMerge [
packages = [ cfg.package ]; { packages = [ cfg.package ]; }
(mkIf (cfg.arguments != [ ]) {
file."${configPath}".text = lib.concatLines cfg.arguments;
file."${configPath}" = sessionVariables."RIPGREP_CONFIG_PATH" = configPath;
mkIf (cfg.arguments != [ ]) { text = lib.concatLines cfg.arguments; }; })
];
sessionVariables = { "RIPGREP_CONFIG_PATH" = configPath; };
};
}; };
} }