jruby-maven-plugins icon indicating copy to clipboard operation
jruby-maven-plugins copied to clipboard

Command-line parameter for gem-maven-plugin?

Open garretwilson opened this issue 14 years ago • 2 comments

I'm trying to upgrade a legacy Maven project that calls Ruby scripts as part of the build. The project doesn't work on Windows because it directly references .rb files. I tried using the gem-maven-plugin version 0.25.1 (because 0.27.0 is broken; see issue 11) with e.g.:

${project.basedir}/bin/autopatch.rb ${test.config}

Unfortunately the plugin thinks that the whole thing is a file and tries to open it, giving a file-not-found error. The second part is actually a command-line parameter, but I didn't see any options for adding a parameter. Is there such an option---or can one be added?

garretwilson avatar Jun 18 '11 22:06 garretwilson

I guess you are referring to the exec goal ?

mvn de.saumya.mojo:gem-maven-plugin:0.25.1:help -Ddetail -Dgoal=exec will give you an overview of the possible parameters you can use.

there is a command parameter which is used by ALL jruby maven plugins goals: 'args' either as command line property or as configuration parameter within the pom.

so a config like ${project.basedir}/bin/autopatch.rb <execArgs>${test.config}</execArgs> will do.

if you need more please speak up - any real world usecase is welcome ;-)

mkristian avatar Jun 19 '11 04:06 mkristian

huups, my xml tags do not show up on github but they do show inside the email - at least ;-)

mkristian avatar Jun 19 '11 04:06 mkristian