nix-config/modules/node.nix
Oliver Davies 703bf836de
All checks were successful
/ check (push) Successful in 55s
Rename modules directory
2025-08-18 11:35:07 +01:00

19 lines
503 B
Nix

{
flake.modules.homeManager.base =
{ config, ... }:
let
inherit (config.xdg) configHome dataHome stateHome;
in
{
xdg.configFile."${config.home.sessionVariables.NPM_CONFIG_USERCONFIG}".text = ''
cache=${configHome}/npm
init-module=${configHome}/npm/config/npm-init.js
logs-dir=${stateHome}/npm/logs
prefix=${dataHome}/npm
'';
home.sessionVariables = {
NPM_CONFIG_USERCONFIG = "${configHome}/npm/npmrc";
};
};
}