Build queue along with other gems

Fixes #6473
This commit is contained in:
Suyog Rao 2017-01-03 09:30:00 -08:00
parent fdda39964d
commit 733a546e9e

View file

@ -112,6 +112,7 @@ namespace "artifact" do
Rake::Task["artifact:build-logstash-core"].invoke
Rake::Task["artifact:build-logstash-core-event"].invoke
Rake::Task["artifact:build-logstash-core-plugin-api"].invoke
Rake::Task["artifact:build-logstash-core-queue-jruby"].invoke
end
# "all-plugins" version of tasks
@ -220,6 +221,24 @@ namespace "artifact" do
end
end
task "build-logstash-core-queue-jruby" do
# regex which matches a Gemfile gem definition for the logstash-core gem and captures the :path option
gem_line_regex = /^\s*gem\s+["']logstash-core-queue-jruby["'](?:\s*,\s*["'][^"^']+["'])?(?:\s*,\s*:path\s*=>\s*["']([^"^']+)["'])?/i
lines = File.readlines("Gemfile")
matches = lines.select{|line| line[gem_line_regex]}
abort("ERROR: Gemfile format error, need a single logstash-core-queue-jruby gem specification") if matches.size != 1
path = matches.first[gem_line_regex, 1]
if path
Rake::Task["plugin:build-local-core-gem"].invoke("logstash-core-queue-jruby", path)
else
puts "The Gemfile should reference \"logstash-core-queue-jruby\" gem locally through :path, but found instead: #{matches}"
exit(1)
end
end
task "prepare" do
if ENV['SKIP_PREPARE'] != "1"
["bootstrap", "plugin:install-default", "artifact:clean-bundle-config"].each {|task| Rake::Task[task].invoke }