Kinda fixing rake to at least only download once
This commit is contained in:
parent
5500be5264
commit
351a7dc5ba
@ -5,11 +5,11 @@ RMQV = '2.8.7'
|
|||||||
|
|
||||||
directory './tmp'
|
directory './tmp'
|
||||||
|
|
||||||
file "./tmp/rabbitmq-java-client-bin-#{RMQV}.tar.gz" => ['./tmp'] do |f|
|
file "./tmp/rabbitmq-java-client-bin-#{RMQV}.tar.gz" => ['./tmp'] do |t|
|
||||||
puts "*** Downloading tarball"
|
puts "*** Downloading tarball"
|
||||||
open("#{RMQ_URI_BASE}/v#{RMQV}/rabbitmq-java-client-bin-#{RMQV}.tar.gz") do |f|
|
open("#{RMQ_URI_BASE}/v#{RMQV}/rabbitmq-java-client-bin-#{RMQV}.tar.gz") do |dl|
|
||||||
open('./tmp/rabbitmq-java-client-bin.tar.gz', 'w') do |out|
|
open(t.name, 'w') do |out|
|
||||||
out.write(f.read)
|
out.write(dl.read)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -18,8 +18,7 @@ file "./tmp/rabbitmq-java-client-bin-#{RMQV}/rabbitmq-client.jar" =>
|
|||||||
["./tmp/rabbitmq-java-client-bin-#{RMQV}.tar.gz"] do
|
["./tmp/rabbitmq-java-client-bin-#{RMQV}.tar.gz"] do
|
||||||
puts "*** Extracting tarball"
|
puts "*** Extracting tarball"
|
||||||
Dir.chdir('./tmp') do
|
Dir.chdir('./tmp') do
|
||||||
`tar xzvf rabbitmq-java-client-bin.tar.gz`
|
sh "tar xzvf rabbitmq-java-client-bin-#{RMQV}.tar.gz"
|
||||||
puts "*** Extracted, exit code = #{$?}"
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user