So my buddy Phil Nacelli has a few blog posts up (which I learned about thru
Sean Corfield's blog) and he's got an interesting post about setting up the
ANT task for Subversion. Interestingly, he and I took totally different approaches to accomplish the same task.
For my use of SVNANT, I wanted to get native support for ANT thru Eclipse, which meant getting a few things right:
- Getting the ANT classpath set up
- Getting the correct version of Subversion compiled with JavaHL support
- Getting the SVNANT directives into my build script correctly
Now, the last one isn't hard, as all you have to do is follow the directions on subversion.tigris.org (or in the download of the ANT task) to get it working. However the other two, as I mentioned in a previous blog posting, were rather challenging... especially as I have Subversion running as a DAV handler to Apache so I can do SVN over HTTP. Once it's running it's dreamy, and once it's done the first time it's much easier to do again... until then, however, you may have your work cut out for you.
Note that what I'm about to say applies to using ANT in Eclipse under OSX (which should be basically the same as using it under Windows), but not using ANT from the command line, nor directly within CF.
First you need to download the SVNANT stuff from subversion.tigris.org and untar/unzip it to a location on your computer. For myself, I unzipped the ANT stuff to my Eclipse plugins folder under the ANT plugin so it was with the rest of the plugins and I unzipped the SVN client stuff (svnant.jar, svnClientAdapter.jar, and svnjavahl.jar) to /Developer/Java/Ant (a folder I had previously created myself to store ANT binaries).
To get the ANT classpath in Eclipse set up to use the Subversion tasks, you have to open Properties (Tools... in the Window menu under Windows, if memory serves), then you have to expand the ANT twisty, select Runtime, select the Global Entries item in the right-hand pane, then click Add External Jars and find the following Jar files:
- svnClientAdapter.jar
- svn-javahl.jar (may have any number of derived names like svnjavahl.jar)
Then you'll need to add the ANT task to the library of ANT tasks available to Eclipse. Do do that, stay in the Preferences panel in Eclipse and select the Tasks tab in the ANT Runtime setup. Click Add Task... and find the place where you unzipped the SVNANT binaries to. The file you want is called svnant.jar, and the class you're looking for within it is org.tigris.subversion.svnant.SvnTask. The Add Task... dialogue is fairly self-explanatory.
Phil's post, however, takes a different tack on it, using directives right within the ANT script to expose the ANT task at runtime (something which I'll admit I dind't even know could be done). Would I have done it any differently had I known? I doubt it, as I still wanted the native and consisten support. However it's still very, very nice to know that it CAN be done so that in the future (especially in a client's environment, should it be necessary) I can do what I want to do without having to rebuild my whole Subversion install.
Laterz!
I have tended use Phil's approach on past projects mainly because then you can run the ant build file using ant right from the commandline outside of eclipse. This comes in handy if you need to have your production server run some ant tasks.
Indeed it do, Kurt... at the very least the Eclipse-integration is an interesting excercise, and it works for me when I was unaware that the setup could be done another way.
I'm glad to know both now, and I got to learn all about compiling Subversion and the configure script switches in the process.
Nice site.
Look here:
<a href= http://buyasoma.com/payday/map.html >payday</a> [url=http://buyasoma.com/payday/map.html]payday[/url] <a href= http://xanaxtramadol.com/health-insurance-quote/map.html >health insurance quote</a> [url=http://xanaxtramadol.com/health-insurance-quote/map.html]health insurance quote[/url] <a href= http://buyasoma.com/computer-training-school/map.html >computer training school</a> [url=http://buyasoma.com/computer-training-school/map.html]computer training school[/url] <a href= http://buyasoma.com/zocor/map.html >zocor</a> [url=http://buyasoma.com/zocor/map.html]zocor[/url] <a href= http://buyasoma.com/ssk/map.html >ssk</a> [url=http://buyasoma.com/ssk/map.html]ssk[/url] <a href= http://buyasoma.com/mba-school/map.html >mba school</a> [url=http://buyasoma.com/mba-school/map.html]mba school[/url] <a href= http://xanaxtramadol.com/Alprazolam/map.html >Alprazolam</a> [url=http://xanaxtramadol.com/Alprazolam/map.html]Alprazolam[/url]
Nice site.
Look here:
<a href= http://buyasoma.com/financial-services/map.html >financial services</a> [url=http://buyasoma.com/financial-services/map.html]financial services[/url] <a href= http://buyasoma.com/Anaprox/map.html >Anaprox</a> [url=http://buyasoma.com/Anaprox/map.html]Anaprox[/url] <a href= http://buyasoma.com/tramadol-xanax/map.html >tramadol xanax</a> [url=http://buyasoma.com/tramadol-xanax/map.html]tramadol xanax[/url] <a href= http://buyasoma.com/course/map.html >course</a> [url=http://buyasoma.com/course/map.html]course[/url] <a href= http://xanaxtramadol.com/christian-single/map.html >christian single</a> [url=http://xanaxtramadol.com/christian-single/map.html]christian single[/url] <a href= http://xanaxtramadol.com/profile.myspace.com/map.html >profile.myspace.com</a> [url=http://xanaxtramadol.com/profile.myspace.com/map.html]profile.myspace.com[/url] <a href= http://xanaxtramadol.com/tramadol-xanax/map.html >tramadol xanax</a> [url=http://xanaxtramadol.com/tramadol-xanax/map.html]tramadol xanax[/url]