Unified home and system modules!
This commit is contained in:
1 parent
cfcc374a69
commit
890b05d352
45 files changed
+389
-566
No files matched your search
@@ -0,0 +1,27 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
let
|
||||
cfg = config.samfelag.modules.dev.git;
|
||||
in
|
||||
{
|
||||
options.samfelag.modules.dev.git = with lib.types; {
|
||||
enable = lib.mkEnableOption "git";
|
||||
userName = lib.my.mkOpt str config.user.name;
|
||||
userEmail = lib.my.mkOpt (nullOr str) null;
|
||||
};
|
||||
config = lib.mkIf cfg.enable {
|
||||
environment.systemPackages = with pkgs; [
|
||||
git
|
||||
];
|
||||
hm.programs.git = {
|
||||
enable = true;
|
||||
|
||||
userName = cfg.userName;
|
||||
userEmail = cfg.userEmail;
|
||||
|
||||
extraConfig = {
|
||||
init.defaultBranch = "main";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in new issue
Block a user