buildr 1.4.11-java → 1.4.12-java
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +22 -0
- data/README.rdoc +2 -0
- data/addon/buildr/checkstyle.rb +1 -1
- data/addon/buildr/gwt.rb +127 -82
- data/addon/buildr/wsgen.rb +19 -1
- data/buildr.gemspec +3 -1
- data/doc/_layouts/default.html +1 -1
- data/doc/download.textile +18 -6
- data/doc/index.textile +9 -18
- data/lib/buildr.rb +1 -0
- data/lib/buildr/clojure.rb +1 -1
- data/lib/buildr/clojure/shell.rb +1 -1
- data/lib/buildr/core/application.rb +3 -2
- data/lib/buildr/core/build.rb +2 -3
- data/lib/buildr/core/cc.rb +1 -1
- data/lib/buildr/core/checks.rb +2 -3
- data/lib/buildr/core/common.rb +1 -1
- data/lib/buildr/core/compile.rb +1 -1
- data/lib/buildr/core/doc.rb +2 -3
- data/lib/buildr/core/environment.rb +1 -1
- data/lib/buildr/core/filter.rb +1 -1
- data/lib/buildr/core/generate.rb +1 -1
- data/lib/buildr/core/help.rb +1 -1
- data/lib/buildr/core/jrebel.rb +1 -1
- data/lib/buildr/core/progressbar.rb +1 -1
- data/lib/buildr/core/project.rb +1 -1
- data/lib/buildr/core/run.rb +2 -2
- data/lib/buildr/core/shell.rb +2 -3
- data/lib/buildr/core/test.rb +1 -1
- data/lib/buildr/core/util.rb +1 -1
- data/lib/buildr/groovy/bdd.rb +1 -1
- data/lib/buildr/groovy/compiler.rb +1 -0
- data/lib/buildr/groovy/doc.rb +4 -4
- data/lib/buildr/groovy/shell.rb +2 -2
- data/lib/buildr/ide/eclipse.rb +1 -1
- data/lib/buildr/ide/idea.rb +45 -14
- data/lib/buildr/java/ant.rb +1 -1
- data/lib/buildr/java/bdd.rb +1 -1
- data/lib/buildr/java/cobertura.rb +1 -1
- data/lib/buildr/java/compiler.rb +3 -3
- data/lib/buildr/java/deprecated.rb +1 -1
- data/lib/buildr/java/doc.rb +3 -3
- data/lib/buildr/java/ecj.rb +2 -2
- data/lib/buildr/java/emma.rb +1 -1
- data/lib/buildr/java/external.rb +2 -2
- data/lib/buildr/java/packaging.rb +2 -3
- data/lib/buildr/java/pom.rb +1 -0
- data/lib/buildr/java/rjb.rb +1 -2
- data/lib/buildr/java/test_result.rb +1 -1
- data/lib/buildr/java/tests.rb +1 -1
- data/lib/buildr/java/version_requirement.rb +1 -1
- data/lib/buildr/packaging/archive.rb +2 -2
- data/lib/buildr/packaging/artifact.rb +1 -1
- data/lib/buildr/packaging/artifact_namespace.rb +1 -1
- data/lib/buildr/packaging/artifact_search.rb +1 -2
- data/lib/buildr/packaging/gems.rb +1 -1
- data/lib/buildr/packaging/package.rb +1 -1
- data/lib/buildr/packaging/tar.rb +1 -1
- data/lib/buildr/packaging/test_jar.rb +32 -0
- data/lib/buildr/packaging/version_requirement.rb +1 -1
- data/lib/buildr/packaging/zip.rb +4 -1
- data/lib/buildr/packaging/ziptask.rb +1 -1
- data/lib/buildr/run.rb +1 -1
- data/lib/buildr/scala/bdd.rb +2 -2
- data/lib/buildr/scala/compiler.rb +2 -1
- data/lib/buildr/scala/doc.rb +5 -4
- data/lib/buildr/scala/shell.rb +2 -2
- data/lib/buildr/scala/tests.rb +2 -2
- data/lib/buildr/shell.rb +2 -2
- data/lib/buildr/version.rb +2 -2
- data/rakelib/doc.rake +4 -5
- data/rakelib/stage.rake +1 -1
- data/spec/core/build_spec.rb +15 -6
- data/spec/core/common_spec.rb +0 -1
- data/spec/core/compile_spec.rb +24 -17
- data/spec/java/bdd_spec.rb +23 -27
- data/spec/java/packaging_spec.rb +35 -0
- data/spec/scala/compiler_spec.rb +8 -6
- metadata +6 -18
data/lib/buildr/java/emma.rb
CHANGED
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
16
|
+
module Buildr #:nodoc:
|
17
17
|
|
18
18
|
# Provides the <code>emma:html</code> and <code>emma:xml</code> tasks.
|
19
19
|
# Require explicitly using <code>require "buildr/emma"</code>.
|
data/lib/buildr/java/external.rb
CHANGED
@@ -13,8 +13,8 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
17
|
-
module Compiler
|
16
|
+
module Buildr #:nodoc:
|
17
|
+
module Compiler #:nodoc:
|
18
18
|
class ExternalJavac< Buildr::Compiler::Javac
|
19
19
|
|
20
20
|
OPTIONS = [:jvm, :warnings, :debug, :deprecation, :source, :target, :lint, :other]
|
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
16
|
+
module Buildr #:nodoc:
|
17
17
|
module Packaging #:nodoc:
|
18
18
|
|
19
19
|
# Adds packaging for Java projects: JAR, WAR, AAR, EAR, Javadoc.
|
@@ -724,7 +724,6 @@ module Buildr
|
|
724
724
|
end
|
725
725
|
end
|
726
726
|
|
727
|
-
|
728
|
-
class Buildr::Project
|
727
|
+
class Buildr::Project #:nodoc:
|
729
728
|
include Buildr::Packaging::Java
|
730
729
|
end
|
data/lib/buildr/java/pom.rb
CHANGED
data/lib/buildr/java/rjb.rb
CHANGED
@@ -18,7 +18,7 @@ require 'yaml'
|
|
18
18
|
require 'rspec/core/formatters/base_formatter'
|
19
19
|
|
20
20
|
module Buildr #:nodoc:
|
21
|
-
module TestFramework
|
21
|
+
module TestFramework #:nodoc:
|
22
22
|
|
23
23
|
# A class used by buildr for jruby based frameworks, so that buildr can know
|
24
24
|
# which tests succeeded/failed.
|
data/lib/buildr/java/tests.rb
CHANGED
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
16
|
+
module Buildr #:nodoc:
|
17
17
|
|
18
18
|
# Base class for ZipTask, TarTask and other archives.
|
19
19
|
class ArchiveTask < Rake::FileTask
|
@@ -186,7 +186,7 @@ module Buildr
|
|
186
186
|
when ArtifactNamespace
|
187
187
|
set |= file.artifacts
|
188
188
|
when Symbol, Hash
|
189
|
-
set |= [artifact(file)]
|
189
|
+
set |= [Buildr.artifact(file)]
|
190
190
|
when /([^:]+:){2,4}/ # A spec as opposed to a file name.
|
191
191
|
set |= [Buildr.artifact(file)]
|
192
192
|
when Project
|
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
16
|
+
module Buildr #:nodoc:
|
17
17
|
|
18
18
|
# An ArtifactNamespace is a hierarchical dictionary used to manage ArtifactRequirements.
|
19
19
|
# It can be used to have different artifact versions per project
|
@@ -13,10 +13,9 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
|
17
16
|
autoload :Hpricot, 'hpricot'
|
18
17
|
|
19
|
-
module Buildr
|
18
|
+
module Buildr #:nodoc:
|
20
19
|
|
21
20
|
# Search best artifact version from remote repositories
|
22
21
|
module ArtifactSearch
|
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
16
|
+
module Buildr #:nodoc:
|
17
17
|
# Methods added to Project to support packaging and tasks for packaging,
|
18
18
|
# installing and uploading packages.
|
19
19
|
module Package
|
data/lib/buildr/packaging/tar.rb
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
autoload :Archive, 'archive/tar/minitar'
|
17
17
|
autoload :Zlib, 'zlib'
|
18
18
|
|
19
|
-
module Buildr
|
19
|
+
module Buildr #:nodoc:
|
20
20
|
|
21
21
|
# The TarTask creates a new Tar file. You can include any number of files and and directories,
|
22
22
|
# use exclusion patterns, and include files into specific directories.
|
@@ -0,0 +1,32 @@
|
|
1
|
+
# Licensed to the Apache Software Foundation (ASF) under one or more
|
2
|
+
# contributor license agreements. See the NOTICE file distributed with this
|
3
|
+
# work for additional information regarding copyright ownership. The ASF
|
4
|
+
# licenses this file to you under the Apache License, Version 2.0 (the
|
5
|
+
# "License"); you may not use this file except in compliance with the License.
|
6
|
+
# You may obtain a copy of the License at
|
7
|
+
#
|
8
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
+
#
|
10
|
+
# Unless required by applicable law or agreed to in writing, software
|
11
|
+
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
12
|
+
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
13
|
+
# License for the specific language governing permissions and limitations under
|
14
|
+
# the License.
|
15
|
+
|
16
|
+
module Buildr #:nodoc:
|
17
|
+
module PackageAsTestJar
|
18
|
+
def package_as_test_jar_spec(spec) #:nodoc:
|
19
|
+
spec.merge(:type => :jar, :classifier => 'test-jar')
|
20
|
+
end
|
21
|
+
|
22
|
+
def package_as_test_jar(file_name) #:nodoc:
|
23
|
+
ZipTask.define_task(file_name).tap do |zip|
|
24
|
+
zip.include :from => [test.compile.target, test.resources.target].compact
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
class Buildr::Project
|
31
|
+
include Buildr::PackageAsTestJar
|
32
|
+
end
|
data/lib/buildr/packaging/zip.rb
CHANGED
@@ -176,8 +176,11 @@ module Zip #:nodoc:
|
|
176
176
|
end
|
177
177
|
|
178
178
|
class ZipEntrySet
|
179
|
+
alias_method :original_push, :"<<"
|
180
|
+
alias_method :push, :"<<"
|
181
|
+
|
179
182
|
def <<(entry)
|
180
|
-
|
183
|
+
original_push(entry) if entry != nil
|
181
184
|
end
|
182
185
|
end
|
183
186
|
end
|
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
16
|
+
module Buildr #:nodoc:
|
17
17
|
|
18
18
|
# The ZipTask creates a new Zip file. You can include any number of files and and directories,
|
19
19
|
# use exclusion patterns, and include files into specific directories.
|
data/lib/buildr/run.rb
CHANGED
data/lib/buildr/scala/bdd.rb
CHANGED
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr::Scala
|
16
|
+
module Buildr::Scala #:nodoc:
|
17
17
|
|
18
18
|
# Specs is a Scala based BDD framework.
|
19
19
|
# To use in your project:
|
@@ -247,7 +247,7 @@ module Buildr::Scala
|
|
247
247
|
end
|
248
248
|
|
249
249
|
# Backwards compatibility stuff. Remove in 1.5.
|
250
|
-
module Buildr
|
250
|
+
module Buildr #:nodoc:
|
251
251
|
ScalaSpecs = Scala::Specs
|
252
252
|
end
|
253
253
|
|
@@ -13,6 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
+
# The Scala Module
|
16
17
|
module Buildr::Scala
|
17
18
|
DEFAULT_VERSION = '2.9.2'
|
18
19
|
|
@@ -381,7 +382,7 @@ end
|
|
381
382
|
# projects that mix Scala and Java code by spotting Scala code first.
|
382
383
|
Buildr::Compiler.compilers.unshift Buildr::Scala::Scalac
|
383
384
|
|
384
|
-
class Buildr::Project
|
385
|
+
class Buildr::Project #:nodoc:
|
385
386
|
include Buildr::Scala::ProjectExtension
|
386
387
|
end
|
387
388
|
|
data/lib/buildr/scala/doc.rb
CHANGED
@@ -13,8 +13,8 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
17
|
-
module Doc
|
16
|
+
module Buildr #:nodoc:
|
17
|
+
module Doc #:nodoc:
|
18
18
|
|
19
19
|
module ScaladocDefaults
|
20
20
|
include Extension
|
@@ -88,12 +88,13 @@ module Buildr
|
|
88
88
|
when Buildr::Scala.version?("2.7")
|
89
89
|
[ "org.scala-tools:vscaladoc:jar:#{VERSION}" ]
|
90
90
|
else
|
91
|
+
warn "VScalaDoc not supported for Scala 2.8+"
|
91
92
|
[]
|
92
93
|
end
|
93
94
|
end
|
94
95
|
end
|
95
96
|
|
96
|
-
Java.classpath << dependencies
|
97
|
+
Java.classpath << lambda { dependencies }
|
97
98
|
|
98
99
|
specify :language => :scala, :source_ext => 'scala'
|
99
100
|
|
@@ -145,7 +146,7 @@ module Buildr
|
|
145
146
|
end
|
146
147
|
end
|
147
148
|
|
148
|
-
class Project
|
149
|
+
class Project #:nodoc:
|
149
150
|
include ScaladocDefaults
|
150
151
|
include Packaging::Scala
|
151
152
|
end
|
data/lib/buildr/scala/shell.rb
CHANGED
@@ -13,8 +13,8 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
17
|
-
module Scala
|
16
|
+
module Buildr #:nodoc:
|
17
|
+
module Scala #:nodoc:
|
18
18
|
class ScalaShell < Buildr::Shell::Base
|
19
19
|
include Buildr::JRebel
|
20
20
|
|
data/lib/buildr/scala/tests.rb
CHANGED
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr::Scala
|
16
|
+
module Buildr::Scala#:nodoc:
|
17
17
|
|
18
18
|
# Mockito is available when running ScalaTest
|
19
19
|
module Mockito
|
@@ -212,7 +212,7 @@ end
|
|
212
212
|
|
213
213
|
|
214
214
|
# Backwards compatibility stuff. Remove in 1.5.
|
215
|
-
module Buildr
|
215
|
+
module Buildr#:nodoc:
|
216
216
|
ScalaCheck = Scala::Check
|
217
217
|
ScalaTest = Scala::ScalaTest
|
218
218
|
end
|
data/lib/buildr/shell.rb
CHANGED
@@ -13,7 +13,7 @@
|
|
13
13
|
# License for the specific language governing permissions and limitations under
|
14
14
|
# the License.
|
15
15
|
|
16
|
-
module Buildr
|
16
|
+
module Buildr #:nodoc:
|
17
17
|
module Shell
|
18
18
|
include Extension
|
19
19
|
|
@@ -178,7 +178,7 @@ module Buildr
|
|
178
178
|
end
|
179
179
|
end
|
180
180
|
|
181
|
-
class Project
|
181
|
+
class Project #:nodoc:
|
182
182
|
include Shell
|
183
183
|
end
|
184
184
|
end
|
data/lib/buildr/version.rb
CHANGED
data/rakelib/doc.rake
CHANGED
@@ -91,11 +91,10 @@ end
|
|
91
91
|
|
92
92
|
# Publish prerequisites to Web site.
|
93
93
|
desc "Publish complete web site"
|
94
|
-
task 'publish' =>
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
sh 'ssh', 'people.apache.org', 'chmod', '-f', '-R', 'g+w', "/www/#{spec.name}.apache.org/*"
|
94
|
+
task 'publish' => %w(site setup-local-site-svn) do
|
95
|
+
puts "Uploading new site ..."
|
96
|
+
sh 'rsync', '--progress', '--recursive', '--delete', '--exclude=.svn','_site/', 'site'
|
97
|
+
task('publish-site-svn').invoke
|
99
98
|
puts 'Done'
|
100
99
|
end
|
101
100
|
|
data/rakelib/stage.rake
CHANGED
@@ -102,7 +102,7 @@ task 'stage' => %w(clobber prepare) do |task, args|
|
|
102
102
|
mkpath '_staged'
|
103
103
|
|
104
104
|
lambda do
|
105
|
-
puts 'Ensuring all files have
|
105
|
+
puts 'Ensuring all files have appropriate group and other permissions...'
|
106
106
|
sh 'find . -type f | xargs chmod go+r'
|
107
107
|
sh 'find . -type d | xargs chmod go+rx'
|
108
108
|
puts '[X] File permissions updated/validted.'
|
data/spec/core/build_spec.rb
CHANGED
@@ -421,9 +421,13 @@ describe Release do
|
|
421
421
|
Release.find.should be_instance_of(SvnRelease)
|
422
422
|
end
|
423
423
|
|
424
|
-
|
425
|
-
|
426
|
-
|
424
|
+
# TravisCI seems to place the tmp directory
|
425
|
+
# sub-ordinate to git repository so this will not work
|
426
|
+
unless ENV['TRAVIS_BUILD_ID']
|
427
|
+
it 'should return nil if no known release process' do
|
428
|
+
Dir.chdir(Dir.tmpdir) do
|
429
|
+
Release.find.should be_nil
|
430
|
+
end
|
427
431
|
end
|
428
432
|
end
|
429
433
|
|
@@ -807,9 +811,14 @@ describe GitRelease do
|
|
807
811
|
end
|
808
812
|
|
809
813
|
describe '#applies_to?' do
|
810
|
-
|
811
|
-
|
812
|
-
|
814
|
+
|
815
|
+
# TravisCI seems to place the tmp directory
|
816
|
+
# sub-ordinate to git repository so this will not work
|
817
|
+
unless ENV['TRAVIS_BUILD_ID']
|
818
|
+
it 'should reject a non-git repo' do
|
819
|
+
Dir.chdir(Dir.tmpdir) do
|
820
|
+
GitRelease.applies_to?.should be_false
|
821
|
+
end
|
813
822
|
end
|
814
823
|
end
|
815
824
|
|