feat: moves the dev shell into teh flake config.

This commit is contained in:
silver 2023-08-06 22:51:24 +01:00
parent 2c5c3094f8
commit 5c41e05c80
2 changed files with 18 additions and 30 deletions

29
dev.nix
View file

@ -1,29 +0,0 @@
# run with: nix-shell dev.nix
# has everything installed for dev
{ pkgs ? import <nixpkgs> {} }:
with pkgs;
let
imports =
let agenixCommit = "42d371d861a227149dc9a7e03350c9ab8b8ddd68";
in
{
agenix = import
(builtins.fetchTarball {
url = "https://github.com/ryantm/agenix/archive/${agenixCommit}.tar.gz";
sha256 = "14sszf5s85i4jd3lc8c167fbxvpj13da45wl1j7wpd20n0fic5c1";
})
{ inherit pkgs; };
};
in mkShell {
# nativeBuildInputs is usually what you want -- tools you need to run
nativeBuildInputs = [
pkgs.buildPackages.git
pkgs.buildPackages.colmena
pkgs.buildPackages.nmap
];
buildInputs = [ imports.agenix.agenix ];
shellHook = ''export EDITOR="${pkgs.nano}/bin/nano --nonewlines"'';
}

View file

@ -23,7 +23,24 @@
skynet_website_2016.url = "gitlab:compsoc1%2Fskynet%2Fwebsite/2016?host=gitlab.skynet.ie";
};
outputs = { self, nixpkgs, ... } @inputs: {
nixConfig.bash-prompt-suffix = "[Skynet Dev] ";
outputs = { self, nixpkgs, agenix, ... } @inputs:
let
pkgs = nixpkgs.legacyPackages.x86_64-linux.pkgs;
in {
# run "nix develop"
devShells.x86_64-linux.default = pkgs.mkShell {
name = "My-project build environment";
nativeBuildInputs = [
pkgs.buildPackages.git
pkgs.buildPackages.colmena
pkgs.buildPackages.nmap
];
buildInputs = [ agenix.packages.x86_64-linux.default ];
shellHook = ''export EDITOR="${pkgs.nano}/bin/nano --nonewlines"'';
};
# https://github.com/zhaofengli/colmena
# colmena apply --on agentjones
# colmena apply --on @dns