fix if hook failure when running under jenkins
Local mode modification done previously faulty. env[‘WORKSPACE’ is not the sufficient discriminator to see if script is running under Jenkins. This fails on the Jenkins parent jobs since those type of jobs don’t have WORKSPACE set.
This commit is contained in:
parent
d4f0323917
commit
9a37922e57
|
@ -98,11 +98,8 @@ def generate_property_file(directory, data)
|
|||
end
|
||||
end
|
||||
|
||||
|
||||
if(ENV['WORKSPACE'])
|
||||
#jenkin mode
|
||||
working_directory = ENV['WORKSPACE']
|
||||
else
|
||||
working_directory = ENV['WORKSPACE'] || '/var/tmp'
|
||||
unless(ENV['BUILD_ID'])
|
||||
#local mode set up fake environment
|
||||
test_directory = 'tools/hudson.model.JDK/'
|
||||
unless(File.exist?(test_directory))
|
||||
|
|
Loading…
Reference in New Issue