-
Notifications
You must be signed in to change notification settings - Fork 7
/
Rakefile
46 lines (36 loc) · 937 Bytes
/
Rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
require 'rake/testtask'
require_relative 'version'
name = "#{$gem_name}-#{$version}.gem"
rule '.class' => '.java' do |t|
sh "javac #{t.source}"
end
desc 'default task'
task :default => [:install_gem]
desc 'Makes a Gem'
task :make_gem do
sh "gem build #{$gem_name}.gemspec"
end
desc 'Install the gem in the standard location'
task :install_gem => [:make_gem] do
sh "gem install #{$gem_name}-#{$version}-java.gem"
end
desc 'Make documentation'
task :make_doc do
sh "yard doc lib/*.rb lib/**/*.rb"
end
desc 'Push project to github'
task :push do
sh "git push origin master"
end
desc 'Push gem to rubygem'
task :push_gem do
sh "push #{name} -p $http_proxy"
end
Rake::TestTask.new do |t|
t.libs << "test"
t.test_files = FileList['test/complete.rb']
t.ruby_opts = ["--server", "-Xinvokedynamic.constants=true", "-J-Xmn512m",
"-J-Xms1024m", "-J-Xmx1024m"]
t.verbose = true
t.warning = true
end