-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathBuildfile
51 lines (36 loc) · 1.39 KB
/
Buildfile
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
46
47
48
49
50
require 'buildr/scala'
require 'buildr/groovy'
# temporary until Scala 2.9.1 is released
if Buildr::Scala.version =~ /2.9.1/
Buildr.settings.build['scala.test'] = "org.scalatest:scalatest_2.9.0:jar:1.6.1"
Buildr.settings.build['scala.check'] = "org.scala-tools.testing:scalacheck_2.9.0-1:jar:1.9"
end
repositories.remote << "http://www.scala-tools.org/repo-snapshots"
repositories.remote << "http://mirrors.ibiblio.org/pub/mirrors/maven2/"
Java.load
VERSION_NUMBER = "2.0.1"
COPYRIGHT = "Copyright (C) 2009-2010 Alex Boisvert"
repositories.release_to[:username] ||= "boisvert"
repositories.release_to[:url] ||= "/tmp/maven2"
repositories.release_to[:permissions] ||= 0664
Project.local_task :run
desc "Stopwatch project"
define "stopwatch2_#{Buildr::Scala.version}" do
project.version = VERSION_NUMBER
project.group = "stopwatch"
manifest["Implementation-Vendor"] = COPYRIGHT
define "core" do
package(:jar, :id => "stopwatch_#{Buildr::Scala.version}")
run.using :main => ["stopwatch2.StopwatchPerformanceSuiteRunner", "-t"],
:java_args => ["-server"]
end
define "web" do
compile.with projects("core")
package(:jar)
run.using :main => "stopwatch2.web.SampleServer"
end
doc.using :scaladoc
doc.from projects('core', 'web')
end
task "perf" => "stopwatch2_#{Buildr::Scala.version}:core:run"
task "sample" => "stopwatch2_#{Buildr::Scala.version}:web:run"