split home-manager into their own submodules
This commit is contained in:
25
modules/dev/javascript/common.nix
Normal file
25
modules/dev/javascript/common.nix
Normal file
@@ -0,0 +1,25 @@
|
||||
{ pkgs }:
|
||||
let
|
||||
packages = builtins.attrValues {
|
||||
inherit (pkgs) nodejs;
|
||||
inherit (pkgs.nodePackages) pnpm;
|
||||
};
|
||||
in
|
||||
{
|
||||
inherit packages;
|
||||
devShell = pkgs.mkShell {
|
||||
inherit packages;
|
||||
name = "javascript-dev-shell";
|
||||
shellHook = ''
|
||||
echo "📦 JavaScript dev environment"
|
||||
'';
|
||||
};
|
||||
sessionVariables = {
|
||||
NPM_CONFIG_USERCONFIG = "\${XDG_CONFIG_HOME}/npm/npmrc";
|
||||
PNPM_HOME = "\${XDG_DATA_HOME}/pnpm";
|
||||
};
|
||||
sessionPath = [
|
||||
"\${XDG_DATA_HOME}/npm/bin"
|
||||
"\${XDG_DATA_HOME}/pnpm"
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user