Cool, welcome to Ruby! Just be careful, it's very addicting! A free classic resource viewed by the community is Why's (Poignant) Guide to Ruby ( http://mislav.uniqpath.com/poignant-guide/). Otherwise, the pickaxe book ( http://pragprog.com/book/ruby3/programming-ruby-1-9) is one of two defacto books for learning, and is just a fun read.
If you appreciate On Sat, Jul 9, 2011 at 1:34 PM, Chris Adams <[email protected]>wrote: > Thanks everybody for all your help! > For now, Allen's method seems to be simple and clean (plus it worked very > well). > > Thurs far, I have been very impressed with buildr. I just wish I knew more > Ruby, but I'm learning :) > > Thanks again. > > - Chris > > > -----Original Message----- > From: [email protected] on behalf of Antoine Toulme > Sent: Sat 7/9/2011 12:16 PM > To: [email protected] > Subject: Re: Creating Zip With All Dependencies > > It would be fun to have a distrib plugin that takes care of most of this, > if > you feel it's a lot of boilerplate. > > Otherwise, this is indeed what I do for my own projects. > https://github.com/intalio/wapama/blob/master/Buildfile > > Let me know if you feel there is a big need for this, maybe create a jira ? > > Antoine > > 2011/7/9 Marc-Andr� Laverdi�re <[email protected]> > > > I personally always used a constant with the list of dependencies to > > package and .include it :) > > > > Is there a better way? It sounds like there is a way to get it done > > automatically... > > Marc-Andr� LAVERDI�RE > > "Perseverance must finish its work so that you may be mature and > complete, > > not lacking anything." -James 1:4 > > http://asimplediscipleslife.blogspot.com/ > > mlaverd.theunixplace.com > > > > > > > > > > > > On Sat, Jul 9, 2011 at 9:05 AM, Allen Riddle <[email protected]> > > wrote: > > > The way I've handled this is to create an assembler sub-project that > > > iterates over the projects and includes them. There might be a slicker > > way, > > > but below is essentially what I've done: > > > > > > define 'eds-assembler' do > > > > > > zip_package = package(:zip, :id => 'your-zip.zip) > > > > > > projects('eds-client', 'eds-core').each do |p| > > > zip_package.include([p] + p.compile.dependencies), :path => "libs") > > > end > > > > > > end > > > > > > On Fri, Jul 8, 2011 at 4:51 PM, Chris Adams <[email protected] > > >wrote: > > > > > >> Hi, > > >> > > >> > > >> > > >> Please forgive my ignorance, as I am knew to Buildr and having a > > >> difficult time figuring out some of the concepts. > > >> > > >> What I am trying to do is create a zip file that contains all of my > > >> applications jar files and the dependent libraries (compile and > runtime > > >> dependencies). Right now, I have only have 1 sub-project (eds-core) > but > > >> ultimately there will be many sub-projects that all will have their > own > > >> set of dependencies and need to get packaged into a single zip file. > > >> > > >> > > >> > > >> I'm assuming there's a way to do this without having to duplicate each > > >> dependency in the zip package project? > > >> > > >> > > >> > > >> Any help is greatly appreciated! > > >> > > >> > > >> > > >> Sincerely, > > >> > > >> Chris Adams > > >> > > >> > > >> > > >> Below is my very basic build file I have right now: > > >> > > >> VERSION_NUMBER = '1.0' > > >> > > >> > > >> > > >> repositories.remote << 'http://www.ibiblio.org/maven2' > > >> > > >> repositories.remote << 'http://repo1.maven.org/maven2' > > >> > > >> > > >> > > >> #Define our dependencies > > >> > > >> LOG4J = 'log4j:log4j:jar:1.2.15' > > >> > > >> DATABASE = struct( > > >> > > >> :pool => 'com.jolbox:bonecp:jar:0.7.1.RELEASE', > > >> > > >> :driver => 'mysql:mysql-connector-java:jar:5.1.17' > > >> > > >> ) > > >> > > >> JAVAMAIL = 'javax.mail:mail:jar:1.4.1' > > >> > > >> > > >> > > >> desc 'EDS Analyst Build Project' > > >> > > >> define 'eds-analyst' do > > >> > > >> project.version = VERSION_NUMBER > > >> > > >> project.group = 'edatasource' > > >> > > >> > > >> > > >> compile.options.target = '1.6' > > >> > > >> manifest['Copyright'] = 'eDataSource (c) 2011' > > >> > > >> > > >> > > >> desc 'The core libraries shared across all the projects' > > >> > > >> define 'eds-core' do > > >> > > >> compile.with LOG4J, transitive(JAVAMAIL), transitive(DATABASE.pool) > > >> > > >> package(:jar) > > >> > > >> end > > >> > > >> > > >> > > >> desc 'Packages up the ea-client' > > >> > > >> define 'eds-client' do > > >> > > >> compile.with project('eds-core').package(:jar) > > >> > > >> package(:zip) > > >> > > >> end > > >> > > >> end > > >> > > >> > > > > > > > > > >
