feat: add 'nodejs' module (and use on 'work' host)

This commit is contained in:
2026-02-23 12:50:47 +01:00
parent aa830fc795
commit 2a07ecef61
3 changed files with 27 additions and 2 deletions

View File

@@ -9,11 +9,9 @@ with pkgs;
htop
jq
nmap
nodejs_24
nvimpager
parallel
pass
pnpm
ripgrep
silver-searcher
sops

View File

@@ -30,6 +30,7 @@ in
../../modules/browser
../../modules/shell
../../modules/music
../../modules/nodejs.nix
../../modules/taskwarrior.nix
../../modules/bruno.nix
../../modules/vscode.nix

26
home/modules/nodejs.nix Normal file
View File

@@ -0,0 +1,26 @@
{
config,
lib,
pkgs,
...
}:
{
options.nodejs = {
enable = lib.mkEnableOption "nodejs (and related packages)";
package = lib.mkOption {
type = lib.types.package;
default = pkgs.nodejs_24;
};
};
config = lib.mkIf config.nodejs.enable {
home.packages = with pkgs; [
config.nodejs.package
pnpm
yarn
biome
tsx
];
};
}