Made git config conditional based on home-manager version

This commit is contained in:
Random936
2025-11-29 21:54:14 -05:00
parent 45619db650
commit 8ab23d4292

View File

@@ -1,16 +1,20 @@
{ ... }: { { options, ... }: {
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;
fonts.fontconfig.enable = true; fonts.fontconfig.enable = true;
programs = { programs = {
home-manager.enable = true; home-manager.enable = true;
git = { git = if builtins.hasAttr "settings" options.programs.git then {
enable = true; enable = true;
settings.user = { settings.user = {
name = "Random936"; name = "Random936";
email = "randomdude936@gmail.com"; email = "randomdude936@gmail.com";
}; };
} else {
enable = true;
userName = "Random936";
userEmail = "randomdude936@gmail.com";
}; };
}; };