d4: nix-flake: language-specific profile works

master
pegasust 2022-12-04 08:41:03 +00:00
parent c11b756d38
commit 6b4c1c2cce
1 changed files with 20 additions and 18 deletions

View File

@ -10,7 +10,7 @@
overlays = [ ];
pkgs = import nixpkgs { system = sys; overlays = overlays; };
shellHookAfter = ''
echo "The input files should be placed under ./data/{submission,example}.txt
echo "The input files should be placed under ./data/{submission,example}.txt"
echo "This problem shares one input between two parts"
'';
py_pkgs = [ pkgs.python310 ];
@ -25,23 +25,25 @@
echo "Run ./run-py.sh for Python's output and ./run-lua.sh for Lua's output"
'' + shellHookAfter;
};
# devShells.${sys} = {
# lua = pkgs.mkShell {
# nativeBuildInputs = lua_pkgs;
# shellHook = ''
# echo "> Lua runtime"
# echo "Run ./run-lua.sh to see solution's output"
# '' + shellHookAfter;
# };
# python = pkgs.mkShell {
# nativeBuildInputs = py_pkgs;
# shellHook = ''
# echo "> Python3 runtime"
# echo "Run ./run-py.sh to see solution's output"
# '' + shellHookAfter;
#
# };
# };
devShells = {
# nix develop ./#lua
lua = pkgs.mkShell {
nativeBuildInputs = lua_pkgs;
shellHook = ''
echo "> Lua runtime"
echo "Run ./run-lua.sh to see the output of the solution"
'' + shellHookAfter;
};
# nix develop ./#python
python = pkgs.mkShell {
nativeBuildInputs = py_pkgs;
shellHook = ''
echo "> Python3 runtime"
echo "Run ./run-py.sh to see the output of the solution"
'' + shellHookAfter;
};
};
}
);
}