chore(develop): optionally block shell

This commit is contained in:
Gregor Kleen 2021-09-27 10:56:23 +02:00
parent bee53feee7
commit bda32ea678
2 changed files with 14 additions and 6 deletions

4
..develop.cmd Executable file
View File

@ -0,0 +1,4 @@
#!/usr/bin/env bash
echo "Develop running... Press Enter to terminate"
read

View File

@ -6,13 +6,17 @@ let
haskellPackages = pkgs.haskellPackages;
develop = pkgs.writeScriptBin "develop" (import ./nix/develop.nix { inherit pkgs; } ''
if [ -n "$ZSH_VERSION" ]; then
autoload -U +X compinit && compinit
autoload -U +X bashcompinit && bashcompinit
fi
eval "$(stack --bash-completion-script stack)"
if [ -x .develop.cmd ]; then
./.develop.cmd
else
if [ -n "$ZSH_VERSION" ]; then
autoload -U +X compinit && compinit
autoload -U +X bashcompinit && bashcompinit
fi
eval "$(stack --bash-completion-script stack)"
$(getent passwd $USER | cut -d: -f 7)
$(getent passwd $USER | cut -d: -f 7)
fi
'');
inDevelop = pkgs.writeScriptBin "in-develop" ''