mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-24 20:02:58 +03:00
my-env: pull --norc shell flag out into shell parameter
As zsh's corresponding flag is called --no-rcs, the build environment couldn't be configured to use zsh at all. Even then the custom PS1 won't work on zsh, but it's usable enough. Close #1040.
This commit is contained in:
parent
6cb91c33d0
commit
a917b7b011
@ -59,7 +59,7 @@
|
||||
{ mkDerivation, substituteAll, pkgs }:
|
||||
{ stdenv ? pkgs.stdenv, name, buildInputs ? []
|
||||
, propagatedBuildInputs ? [], gcc ? stdenv.gcc, cTags ? [], extraCmds ? ""
|
||||
, cleanupCmds ? "", shell ? "${pkgs.bashInteractive}/bin/bash"}:
|
||||
, cleanupCmds ? "", shell ? "${pkgs.bashInteractive}/bin/bash --norc"}:
|
||||
|
||||
mkDerivation {
|
||||
# The setup.sh script from stdenv will expect the native build inputs in
|
||||
@ -146,8 +146,8 @@ mkDerivation {
|
||||
EOF
|
||||
|
||||
mkdir -p $out/bin
|
||||
sed -e s,@shell@,${shell}, -e s,@myenvpath@,$out/dev-envs/${name}, \
|
||||
-e s,@name@,${name}, ${./loadenv.sh} > $out/bin/load-env-${name}
|
||||
sed -e 's,@shell@,${shell},' -e s,@myenvpath@,$out/dev-envs/${name}, \
|
||||
-e 's,@name@,${name},' ${./loadenv.sh} > $out/bin/load-env-${name}
|
||||
chmod +x $out/bin/load-env-${name}
|
||||
'';
|
||||
}
|
||||
|
@ -10,5 +10,5 @@ export buildInputs
|
||||
export NIX_STRIP_DEBUG=0
|
||||
export TZ="$OLDTZ"
|
||||
|
||||
@shell@ --norc
|
||||
@shell@
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user