Do not blow up in install stage when TASK_WORK is not set. No issue #
authorTom Clegg <tom@curoverse.com>
Tue, 26 Aug 2014 03:51:25 +0000 (23:51 -0400)
committerTom Clegg <tom@curoverse.com>
Tue, 26 Aug 2014 03:51:25 +0000 (23:51 -0400)
sdk/cli/bin/crunch-job

index 395ea2ac67b8babc056550da1aea5bf710bf2e57..638353d76fae023f4cf2c874c60cb7ea8c40dc2b 100755 (executable)
@@ -1504,8 +1504,10 @@ my $commit = $ENV{"CRUNCH_SRC_COMMIT"};
 my $repo = $ENV{"CRUNCH_SRC_URL"};
 my $task_work = $ENV{"TASK_WORK"};
 
-make_path $task_work;
--e $task_work or die "Failed to create temporary working directory ($task_work): $!";
+if ($task_work) {
+    make_path $task_work;
+    -e $task_work or die "Failed to create temporary working directory ($task_work): $!";
+}
 
 open L, ">", "$destdir.lock" or die "$destdir.lock: $!";
 flock L, LOCK_EX;