Re: Maven release plugin not honoring -Darguments

2011-12-30 Thread Ansgar Konermann
Am 27.09.2011 14:48 schrieb David Blevins david.blev...@gmail.com:

 Is it a known issue that the release plugin does not honor the
-Darguments?

 Specifically, I'm attempting to:

  mvn release:prepare -DdryRun=true -Darguments=-DskipTests=true
 -DfailIfNoTests=false


Try:

mvn release:prepare -DdryRun=true -Darguments=-DskipTests=true
 -DfailIfNoTests=false

Notice the slightly different quoting (before -Darguments). Works well for
me.

Best regards

Ansgar

 It takes 40 minutes to get through a dryRun with tests on.  We still have
several kinks in the build to work out before the release plugin will work,
so obviously running with tests on every dryRun is just making a hard task
impossible.

 maven 3.0.3, apache-10 parent pom, maven-release-plugin 2.1


 -David


 -
 To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
 For additional commands, e-mail: dev-h...@maven.apache.org



Re: Maven release plugin not honoring -Darguments

2011-12-30 Thread Benson Margulies
This situation was discussed once before. The author of this pom, as I
recall, had pretty strong feelings about it.

You can work with it by making your own profile named apache_release
that has the additional stuff you want, or by overriding the execution
configuration in your pom to use your preferred arguments/.

On Thu, Dec 29, 2011 at 10:18 PM, David Blevins david.blev...@gmail.com wrote:
 On Tue, Sep 27, 2011 at 1:09 PM, David Blevins david.blev...@gmail.com 
 wrote:
 Did some more digging and it seems the issue is in the apache-10 parent pom. 
  If you alter it like so, the arguments are passed as expected:

    plugin
      groupIdorg.apache.maven.plugins/groupId
      artifactIdmaven-release-plugin/artifactId
      version2.1/version
      configuration
        useReleaseProfilefalse/useReleaseProfile
        goalsdeploy/goals
        !--arguments-Papache-release/arguments--
        arguments-Papache-release ${arguments}/arguments
      /configuration
    /plugin

 Seems this is just a mistake as the full config as reported via -X contains 
 quite a bit of foo${foo}/foo style declarations.  We likely just missed 
 it here.

 Going to use a hacked parent pom for the moment but it would be great if we 
 could get an apache-11 pom out soonish.

 This came up again.  Posting so I don't forget to deal with it when I
 have time.  Will file an issue with a patch tomorrow unless someone
 beats me to it.


 -David

 -
 To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
 For additional commands, e-mail: dev-h...@maven.apache.org


-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



Re: Maven release plugin not honoring -Darguments

2011-12-30 Thread David Blevins
An FYI on the escaping/quoting as that's come up twice and isn't the issue.

public class Arguments {
public static void main(String[] args) {

for (String arg : args) {
System.out.printf([%s], arg);
}

System.out.println();
}
}


$ java Arguments mvn release:prepare -DdryRun=true 
-Darguments=-DskipTests=true -DfailIfNoTests=false
[mvn][release:prepare][-DdryRun=true][-Darguments=-DskipTests=true 
-DfailIfNoTests=false]

$ java Arguments mvn release:prepare -DdryRun=true 
-Darguments=-DskipTests=true -DfailIfNoTests=false
[mvn][release:prepare][-DdryRun=true][-Darguments=-DskipTests=true 
-DfailIfNoTests=false]

$ java Arguments mvn release:prepare -DdryRun=true 
-Darguments=-DskipTests=true -DfailIfNoTests=false
[mvn][release:prepare][-DdryRun=true][-Darguments=-DskipTests=true 
-DfailIfNoTests=false]

$ java Arguments mvn release:prepare -DdryRun=true 
-Darguments=-DskipTests=true' '-DfailIfNoTests=false
[mvn][release:prepare][-DdryRun=true][-Darguments=-DskipTests=true 
-DfailIfNoTests=false]

$ java Arguments mvn release:prepare -DdryRun=true 
-Darguments=-DskipTests=true\ -DfailIfNoTests=false
[mvn][release:prepare][-DdryRun=true][-Darguments=-DskipTests=true 
-DfailIfNoTests=false]

The next one just to be goofy :)

$ java Arguments mvn release:prepare -DdryRun=true 
-Dargum'en'ts=-Ds'k'ipTests=true\ -DfailIfNoTest's'=false
[mvn][release:prepare][-DdryRun=true][-Darguments=-DskipTests=true 
-DfailIfNoTests=false]

And finally an actually broken one:

$ java Arguments mvn release:prepare -DdryRun=true -Darguments=-DskipTests=true 
-DfailIfNoTests=false
[mvn][release:prepare][-DdryRun=true][-Darguments=-DskipTests=true][-DfailIfNoTests=false]


The problem isn't with the plugin but the Apache parent pom.  Thanks, Benson, 
for the feedback on that.  There're half dozen committers on that pom so I'm 
not sure who has the objection to allowing -Darguments to be used.

I've created this jira and attached a patch.  Hopefully we can either fix it or 
document it as intentionally not working and give reasons and workarounds like 
the ones you suggest.  I'm fine with either outcome.

  https://issues.apache.org/jira/browse/MPOM-35

On a side note,... Happy new year to all! :)


-David

On Dec 30, 2011, at 2:22 AM, Ansgar Konermann wrote:

 Am 27.09.2011 14:48 schrieb David Blevins david.blev...@gmail.com:
 
 Is it a known issue that the release plugin does not honor the
 -Darguments?
 
 Specifically, I'm attempting to:
 
 mvn release:prepare -DdryRun=true -Darguments=-DskipTests=true
 -DfailIfNoTests=false
 
 
 Try:
 
 mvn release:prepare -DdryRun=true -Darguments=-DskipTests=true
 -DfailIfNoTests=false
 
 Notice the slightly different quoting (before -Darguments). Works well for
 me.
 
 Best regards
 
 Ansgar
 
 It takes 40 minutes to get through a dryRun with tests on.  We still have
 several kinks in the build to work out before the release plugin will work,
 so obviously running with tests on every dryRun is just making a hard task
 impossible.
 
 maven 3.0.3, apache-10 parent pom, maven-release-plugin 2.1
 
 
 -David
 
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
 For additional commands, e-mail: dev-h...@maven.apache.org
 


-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



Re: Maven release plugin not honoring -Darguments

2011-12-29 Thread David Blevins
On Tue, Sep 27, 2011 at 1:09 PM, David Blevins david.blev...@gmail.com wrote:
 Did some more digging and it seems the issue is in the apache-10 parent pom.  
 If you alter it like so, the arguments are passed as expected:

    plugin
      groupIdorg.apache.maven.plugins/groupId
      artifactIdmaven-release-plugin/artifactId
      version2.1/version
      configuration
        useReleaseProfilefalse/useReleaseProfile
        goalsdeploy/goals
        !--arguments-Papache-release/arguments--
        arguments-Papache-release ${arguments}/arguments
      /configuration
    /plugin

 Seems this is just a mistake as the full config as reported via -X contains 
 quite a bit of foo${foo}/foo style declarations.  We likely just missed 
 it here.

 Going to use a hacked parent pom for the moment but it would be great if we 
 could get an apache-11 pom out soonish.

This came up again.  Posting so I don't forget to deal with it when I
have time.  Will file an issue with a patch tomorrow unless someone
beats me to it.


-David

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



Re: Maven release plugin not honoring -Darguments

2011-09-27 Thread David Jencks
IIRC you have to include your forked maven arguments in the release plugin 
configuration under
arguments-DskipTests=true  -DfailIfNoTests=false/arguments

Perhaps someone else can say _why_ the m-r-p is set up so you can't set this on 
the command line?

thanks
david jencks 

On Sep 27, 2011, at 5:40 AM, David Blevins wrote:

 Is it a known issue that the release plugin does not honor the -Darguments?
 
 Specifically, I'm attempting to:
 
  mvn release:prepare -DdryRun=true -Darguments=-DskipTests=true  
 -DfailIfNoTests=false
 
 It takes 40 minutes to get through a dryRun with tests on.  We still have 
 several kinks in the build to work out before the release plugin will work, 
 so obviously running with tests on every dryRun is just making a hard task 
 impossible.
 
 maven 3.0.3, apache-10 parent pom, maven-release-plugin 2.1
 
 
 -David
 
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
 For additional commands, e-mail: dev-h...@maven.apache.org
 


-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



Re: Maven release plugin not honoring -Darguments

2011-09-27 Thread Stephen Connolly
you can if you understand shell escaping.

- Stephen

---
Sent from my Android phone, so random spelling mistakes, random nonsense
words and other nonsense are a direct result of using swype to type on the
screen
On 27 Sep 2011 17:58, David Jencks david_jen...@yahoo.com wrote:
 IIRC you have to include your forked maven arguments in the release plugin
configuration under
 arguments-DskipTests=true -DfailIfNoTests=false/arguments

 Perhaps someone else can say _why_ the m-r-p is set up so you can't set
this on the command line?

 thanks
 david jencks

 On Sep 27, 2011, at 5:40 AM, David Blevins wrote:

 Is it a known issue that the release plugin does not honor the
-Darguments?

 Specifically, I'm attempting to:

 mvn release:prepare -DdryRun=true -Darguments=-DskipTests=true
-DfailIfNoTests=false

 It takes 40 minutes to get through a dryRun with tests on. We still have
several kinks in the build to work out before the release plugin will work,
so obviously running with tests on every dryRun is just making a hard task
impossible.

 maven 3.0.3, apache-10 parent pom, maven-release-plugin 2.1


 -David


 -
 To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
 For additional commands, e-mail: dev-h...@maven.apache.org



 -
 To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
 For additional commands, e-mail: dev-h...@maven.apache.org



Re: Maven release plugin not honoring -Darguments

2011-09-27 Thread David Blevins
That's not it, the quoting was fine.  Even with a single argument with no 
spaces to -Darguments it still does not work.

Did some more digging and it seems the issue is in the apache-10 parent pom.  
If you alter it like so, the arguments are passed as expected:

plugin
  groupIdorg.apache.maven.plugins/groupId
  artifactIdmaven-release-plugin/artifactId
  version2.1/version
  configuration
useReleaseProfilefalse/useReleaseProfile
goalsdeploy/goals
!--arguments-Papache-release/arguments--
arguments-Papache-release ${arguments}/arguments
  /configuration
/plugin

Seems this is just a mistake as the full config as reported via -X contains 
quite a bit of foo${foo}/foo style declarations.  We likely just missed it 
here.

Going to use a hacked parent pom for the moment but it would be great if we 
could get an apache-11 pom out soonish.


-David


On Sep 27, 2011, at 10:54 AM, Stephen Connolly wrote:

 you can if you understand shell escaping.
 
 - Stephen
 
 ---
 Sent from my Android phone, so random spelling mistakes, random nonsense
 words and other nonsense are a direct result of using swype to type on the
 screen
 On 27 Sep 2011 17:58, David Jencks david_jen...@yahoo.com wrote:
 IIRC you have to include your forked maven arguments in the release plugin
 configuration under
 arguments-DskipTests=true -DfailIfNoTests=false/arguments
 
 Perhaps someone else can say _why_ the m-r-p is set up so you can't set
 this on the command line?
 
 thanks
 david jencks
 
 On Sep 27, 2011, at 5:40 AM, David Blevins wrote:
 
 Is it a known issue that the release plugin does not honor the
 -Darguments?
 
 Specifically, I'm attempting to:
 
 mvn release:prepare -DdryRun=true -Darguments=-DskipTests=true
 -DfailIfNoTests=false
 
 It takes 40 minutes to get through a dryRun with tests on. We still have
 several kinks in the build to work out before the release plugin will work,
 so obviously running with tests on every dryRun is just making a hard task
 impossible.
 
 maven 3.0.3, apache-10 parent pom, maven-release-plugin 2.1
 
 
 -David
 
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
 For additional commands, e-mail: dev-h...@maven.apache.org
 
 
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
 For additional commands, e-mail: dev-h...@maven.apache.org
 


-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org