buildr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex Boisvert <boisv...@intalio.com>
Subject Re: Quick Start Documentation
Date Wed, 29 Jul 2009 22:54:01 GMT
And now a year later, I realize it can be written more succinctly as:

task :unzip_birt => unzip(_("target/birt") => BIRT_WAR) do
  compile.with Dir[_("target/birt/WEB-INF/lib") + "/*.jar"]
end

task :compile => :unzip_birt

alex

On Wed, Jul 29, 2009 at 3:26 PM, Alex Boisvert <boisvert@intalio.com> wrote:

> For what it's worth, I've done a similar "download, unzip, find the jars,
> compile with the jars" job in a project last year...  I didn't feel like
> creating artifacts for all the jars included in Eclipse BIRT... and it
> looked like:
>
> BIRT_WAR = artifact("org.eclipse.birt:birt-webapp:war:2.3.0")
>
> def unzip_birt_libs
>   BIRT_WAR.invoke
>   unless File.exist?(BIRT_TARGET)
>     p "Unzipping BIRT libraries..."
>     unzip(BIRT_TARGET => BIRT_WAR).extract
>   end
>   Dir["#{File.join(BIRT_TARGET, "WEB-INF", "lib")}/*.jar"].map { |jar|
> file(jar) }
> end
>
> and later,
>
> compile.with unzip_birt_libs
>
> alex
>
>>
>>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message