about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2015-05-21T15·04+0200
committerEelco Dolstra <eelco.dolstra@logicblox.com>2015-05-21T15·04+0200
commite0a068cb97225dcdc539c8989e96013399e1f9c9 (patch)
treeb0ed653708422986b56b13d4502bea14052397bc
parent4ca5a9dcfd577487f8a5b192e8ec525c5baad8cb (diff)
nix-shell: Barf if -p and -E are both used
Closes #454, #455.
-rwxr-xr-xscripts/nix-build.in2
1 files changed, 2 insertions, 0 deletions
diff --git a/scripts/nix-build.in b/scripts/nix-build.in
index 5745a1e06e48..5e988cc411f8 100755
--- a/scripts/nix-build.in
+++ b/scripts/nix-build.in
@@ -217,6 +217,8 @@ for (my $n = 0; $n < scalar @ARGV; $n++) {
     }
 }
 
+die "$0: ‘-p’ and ‘-E’ are mutually exclusive\n" if $packages && $fromArgs;
+
 if ($packages) {
     push @instArgs, "--expr";
     @exprs = (