Author: vborja
Date: Mon Apr 7 14:15:36 2008
New Revision: 645698
URL: http://svn.apache.org/viewvc?rev=645698&view=rev
Log:
Fixed EarTask thanks to Tomas Carlsson
Modified:
incubator/buildr/trunk/lib/buildr/core/util.rb
incubator/buildr/trunk/lib/buildr/java/packaging.rb
Modified: incubator/buildr/trunk/lib/buildr/core/util.rb
URL:
http://svn.apache.org/viewvc/incubator/buildr/trunk/lib/buildr/core/util.rb?rev=645698&r1=645697&r2=645698&view=diff
==============================================================================
--- incubator/buildr/trunk/lib/buildr/core/util.rb (original)
+++ incubator/buildr/trunk/lib/buildr/core/util.rb Mon Apr 7 14:15:36 2008
@@ -118,7 +118,7 @@
end
def relative_path(to, from = ".")
- to, from = File.expand_path(to, "/"), File.expand_path(from, "/")
+ to, from = File.expand_path(to.to_s, "/"), File.expand_path(from.to_s,
"/")
Pathname.new(to).relative_path_from(Pathname.new(from)).to_s
end
end
Modified: incubator/buildr/trunk/lib/buildr/java/packaging.rb
URL:
http://svn.apache.org/viewvc/incubator/buildr/trunk/lib/buildr/java/packaging.rb?rev=645698&r1=645697&r2=645698&view=diff
==============================================================================
--- incubator/buildr/trunk/lib/buildr/java/packaging.rb (original)
+++ incubator/buildr/trunk/lib/buildr/java/packaging.rb Mon Apr 7 14:15:36 2008
@@ -460,7 +460,7 @@
from = component[:path]
@classpath = @components.select { |comp| comp[:type] == :lib }.
map do |lib|
- lib_path = File.join(lib[:path].to_s, lib[:artifact].pathmap('%f'))
+ lib_path = File.join(lib[:path].to_s,
lib[:artifact].to_s.pathmap('%f'))
Util.relative_path(lib_path, from)
end
end
@@ -474,7 +474,7 @@
xml.application do
xml.tag! 'display-name', display_name
@components.each do |comp|
- uri = relative_path(File.join(comp[:path].to_s,
comp[:artifact].pathmap('%f')))
+ uri = Util.relative_path(File.join(comp[:path].to_s,
comp[:artifact].to_s.pathmap('%f')))
case comp[:type]
when :war
xml.module :id=>comp[:id] do