diff --git a/README.md b/README.md index daf27d3..4b620fd 100644 --- a/README.md +++ b/README.md @@ -121,6 +121,15 @@ just age -e -o ## Development +### Development Shell + +A Nix development shell is available with useful tools for working on this configuration: + +```bash +# Enter the development shell +nix develop +``` + ### Formatting Code is formatted using `treefmt-nix` with: diff --git a/devshell.nix b/devshell.nix new file mode 100644 index 0000000..1120b40 --- /dev/null +++ b/devshell.nix @@ -0,0 +1,35 @@ +{inputs, ...}: { + perSystem = { + pkgs, + system, + ... + }: { + devShells.default = pkgs.mkShell { + name = "nixos-config"; + packages = with pkgs; [ + # Nix tools + nil # Nix LSP + alejandra # Nix formatter + nix-diff # Compare derivations + nix-tree # Visualize dependencies + nvd # Nix version diff + + # Secrets management + inputs.agenix.packages.${system}.default + age + + # Deployment + just + + # Git + git + jujutsu + ]; + + shellHook = '' + echo "🔧 NixOS Configuration Development Shell" + echo " Run 'just' to see available commands" + ''; + }; + }; +} diff --git a/flake.nix b/flake.nix index 938f52c..6a54693 100644 --- a/flake.nix +++ b/flake.nix @@ -6,6 +6,7 @@ imports = [ inputs.agenix-rekey.flakeModule ./formatter.nix + ./devshell.nix ./hosts ]; systems = [