feat: rework to modular

This commit is contained in:
eric
2026-04-10 17:25:08 +02:00
parent 28dad81816
commit 99658b27dc
39 changed files with 738 additions and 211 deletions

19
modules/base/core.nix Normal file
View File

@@ -0,0 +1,19 @@
{ lib, pkgs, ... }:
{
home.packages = with pkgs; [
age
curl
fd
git
jq
just
ripgrep
sops
];
programs.git = {
enable = true;
lfs.enable = true;
signing.format = lib.mkDefault "openpgp";
};
}

11
modules/base/fonts.nix Normal file
View File

@@ -0,0 +1,11 @@
{ lib, pkgs, ... }:
let
jetbrainsMono = lib.attrByPath [ "nerd-fonts" "jetbrains-mono" ] null pkgs;
in
{
fonts.fontconfig.enable = pkgs.stdenv.isLinux;
home.packages = builtins.filter (pkg: pkg != null) [
jetbrainsMono
];
}

14
modules/base/nix.nix Normal file
View File

@@ -0,0 +1,14 @@
{ lib, pkgs, ... }:
{
programs.home-manager.enable = true;
nix.package = lib.mkDefault pkgs.nix;
nix.settings = {
experimental-features = [
"nix-command"
"flakes"
];
warn-dirty = false;
};
}

20
modules/base/shell.nix Normal file
View File

@@ -0,0 +1,20 @@
{ ... }:
{
programs.bash.enable = true;
programs.zsh = {
enable = true;
autocd = true;
enableCompletion = true;
shellAliases = {
l = "ls -CF";
la = "ls -A";
ll = "ls -alF";
};
};
programs.direnv = {
enable = true;
nix-direnv.enable = true;
};
}