Hi,

On Mar 2, 2009, at 3:04 PM, Daniel Spiewak wrote:

I think that you're going to have to do an RJB import. If you were using JRuby, you would need to use an unconventional syntax there as well since they make the same assumption.

Thanks for the verification.

In case anyone else is trying to work with bnd: I did get the command line invocation to work using RJB.import("aQute.bnd.main.bnd").main(args). However, it turns out that bnd's command line interface does System.exit (even on success), so I switched to using the ant tasks instead.

Rhett




Daniel

On Mar 2, 2009, at 2:24 PM, Rhett Sutphin <rh...@detailedbalance.net> wrote:

Hi,

I'm trying to invoke the command-line version of bnd (http://www.aqute.biz/Code/Bnd ) from buildr. The utility has a main class (aQute.bnd.main.bnd) which I'm trying to invoke in buildr like so:

Java.aQute.bnd.main.bnd.main(args)

I get the error "No arguments expected" for this. Tracing into the code, this seems to come from java/rjb.rb, which assumes that the class name starts with a capital letter and so is treating the whole thing as a series of packages.

This is a reasonable assumption IMO, but I'm wondering if there's a workaround for loading a class which doesn't fit it. Do I need to just do Rjb.import? Or is there an rjb/jruby cross-compatible syntax that I'm missing?

Thanks,
Rhett

Reply via email to