Merge pull request #1177 from dezgeg/bash-env-breakage

nix-shell: Fix 'nix-shell --command' doing nothing without TTY
This commit is contained in:
Eelco Dolstra 2017-01-09 16:44:42 +01:00 committed by GitHub
commit f61337fdb3

View file

@ -81,7 +81,8 @@ int main(int argc, char ** argv)
auto pure = false;
auto fromArgs = false;
auto packages = false;
auto interactive = true;
// Same condition as bash uses for interactive shells
auto interactive = isatty(STDIN_FILENO) && isatty(STDERR_FILENO);
Strings instArgs;
Strings buildArgs;