migrated all languages to devshell

This commit is contained in:
2025-04-18 21:29:02 -06:00
parent ecb9f386ce
commit 023744a872
11 changed files with 256 additions and 94 deletions

View File

@@ -4,16 +4,34 @@
pkgs,
...
}:
let
packages = builtins.attrValues {
inherit (pkgs)
nixfmt-rfc-style # formatting
cachix # binary cache management
nixd # language server for Nix
statix # linter for Nix expressions
;
};
in
{
options.my.dev.nix.enable = lib.mkEnableOption "enable";
options = {
my.dev.nix.enable = lib.mkEnableOption "Install Nix tooling globally";
devShells.nix = lib.mkOption {
type = lib.types.package;
default = pkgs.mkShell {
inherit packages;
name = "nix-dev-shell";
shellHook = ''
echo " Nix dev environment"
'';
};
description = "Nix/NixOS development shell with formatter, linter, LSP, and Cachix";
};
};
config = lib.mkIf config.my.dev.nix.enable {
users.users.jawz.packages = builtins.attrValues {
inherit (pkgs)
nixfmt-rfc-style # formating
cachix # why spend time compiling?
nixd # language server
statix # linter
;
users.users.jawz = {
inherit packages;
};
};
}