about summary refs log tree commit diff
path: root/src/nix-build/nix-build.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2017-07-03T09·54+0200
committerEelco Dolstra <edolstra@gmail.com>2017-07-03T09·54+0200
commit0a5a867758285ee07334a44ede336ae75fd51c50 (patch)
tree7b3cfe5a2ffc52ebe9a27c6a038aadc9774d3e58 /src/nix-build/nix-build.cc
parentfcca702a96a8ca0e73f6d035052c30121776aeba (diff)
nix-shell: Respect --dry-run
Fixes #824.
Diffstat (limited to 'src/nix-build/nix-build.cc')
-rwxr-xr-xsrc/nix-build/nix-build.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/nix-build/nix-build.cc b/src/nix-build/nix-build.cc
index 42d68fdfdd70..dc80dd6a583e 100755
--- a/src/nix-build/nix-build.cc
+++ b/src/nix-build/nix-build.cc
@@ -390,6 +390,8 @@ int main(int argc, char ** argv)
                     maybePrintExecError(e);
                 }
 
+                if (dryRun) return;
+
                 // Set the environment.
                 auto env = getEnv();