Files
NixOS/modules/dev/haskell/home.nix
Danilo Reyes 66483c89ac
All checks were successful
MCP Tests / mcp-tests (push) Successful in 19s
code rules
2026-03-23 15:49:51 -06:00

42 lines
791 B
Nix

{
config,
inputs,
lib,
osConfig ? null,
pkgs,
...
}:
let
hm = inputs.self.lib.hmModule {
inherit
config
inputs
osConfig
;
optionPath = [
"dev"
"haskell"
];
};
cfg = config.my.dev.haskell;
feature = import ./common.nix { inherit pkgs; };
in
{
options.my.dev.haskell.enable = lib.mkEnableOption "Install Haskell tooling globally";
config = lib.mkMerge [
{
my.dev.haskell.enable = lib.mkDefault hm.enabledByDefault;
}
(lib.mkIf cfg.enable {
home = {
inherit (feature) packages;
sessionVariables = {
CABAL_DIR = "${config.xdg.cacheHome}/cabal";
STACK_ROOT = "${config.xdg.dataHome}/stack";
GHCUP_USE_XDG_DIRS = "true";
};
};
})
];
}