mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-26 04:43:09 +03:00
treewide: change $IN_NIX_SHELL handling
... to be compatible with https://github.com/NixOS/nix/pull/933 while not breaking compatibility with current nix.
This commit is contained in:
parent
18c0be1b3a
commit
d4de02c46e
@ -71,7 +71,7 @@ rec {
|
||||
+ (if pathExists suffixFile then fileContents suffixFile else "pre-git");
|
||||
|
||||
# Whether we're being called by nix-shell.
|
||||
inNixShell = builtins.getEnv "IN_NIX_SHELL" == "1";
|
||||
inNixShell = builtins.getEnv "IN_NIX_SHELL" != "";
|
||||
|
||||
# Return minimum/maximum of two numbers.
|
||||
min = x: y: if x < y then x else y;
|
||||
|
@ -36,7 +36,7 @@ in stdenv.mkDerivation rec {
|
||||
# mv effect-*/effect $out/pkgs/effect
|
||||
mv requests-*/requests $out/pkgs/
|
||||
|
||||
if [ "$IN_NIX_SHELL" != "1" ]; then
|
||||
if [ -z "$IN_NIX_SHELL" ]; then
|
||||
if [ -e git-export ]; then
|
||||
mv git-export/src/pypi2nix $out/pkgs/pypi2nix
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user