You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "james strachan (JIRA)" <ji...@codehaus.org> on 2010/10/06 13:06:32 UTC
[jira] Created: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
-----------------------------------------------------------------------------------------------
Key: MRELEASE-605
URL: http://jira.codehaus.org/browse/MRELEASE-605
Project: Maven 2.x Release Plugin
Issue Type: Improvement
Affects Versions: 2.1
Reporter: james strachan
as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
Ideally if pushChanges is false, it should use a value of
{code}
<release-altGitURL>scm:git:file://${baseDir}</release-altGitURL>
{code}
so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "james strachan (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=238393#action_238393 ]
james strachan commented on MRELEASE-605:
-----------------------------------------
Thanks - thats a much simpler workaround :-)
Though even better would be to just let the release plugin default to using the local repo automatically
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: http://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
> Fix For: 2.2
>
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "james strachan (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=237649#action_237649 ]
james strachan commented on MRELEASE-605:
-----------------------------------------
BTW using 2.1 you can do a release using pushChanges as false. For those interested here's how I did it...
* add the following to your pom (the version and pushChanges are the biggies)
{code}
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>2.1</version>
<configuration>
<pushChanges>false</pushChanges>
<autoVersionSubmodules>true</autoVersionSubmodules>
<allowTimestampedSnapshots>false</allowTimestampedSnapshots>
<arguments>-Prelease</arguments>
</configuration>
</plugin>
{code}
* in your pom.xml make sure you set the scm section as follows
{code}
<scm>
<!-- TODO - hack this in your ~/.m2/settings.xml to point to your local checkout for releases -->
<developerConnection>${release-altGitURL}</developerConnection>
...
</scm>
{code}
* in your ~/.m2/settings.xml make sure you have this...
{code}
<settings>
<profiles>
<profile>
<id>release</id>
<properties>
<release-altGitURL>scm:git:file:///directory/where/my/code/is</release-altGitURL>
</properties>
</profile>
</profiles>
{code}
* then when running the release plugin use
{code}
mvn release:prepare -Prelease
mvn release:perform -Prelease
{code}
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: http://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=237655#action_237655 ]
Brett Porter commented on MRELEASE-605:
---------------------------------------
It shouldn't change the devConnection URL, but it should know to clone from the current directory instead if the flag is false. For git, it probably always makes sense to do this instead of wasting bandwidth cloning the repo, since it will be a clean copy.
However, in some situations you may want the opposite - to ensure a push has occurred before performing the release. That might need to a separate check.
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: http://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=237656#action_237656 ]
Brett Porter commented on MRELEASE-605:
---------------------------------------
btw a simpler workaround is probably to use:
{code}
mvn release:perform -DconnectionUrl=scm:git:file:///directory/where/my/code/is
{code}
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: http://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
> Fix For: 2.2
>
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Brett Porter updated MRELEASE-605:
----------------------------------
Fix Version/s: 2.2
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: http://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
> Fix For: 2.2
>
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "james strachan (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
james strachan updated MRELEASE-605:
------------------------------------
Description:
as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
Ideally if pushChanges is false, it should use a value of
{code}
<scm>
<developerConnectionL>scm:git:file://${baseDir}</developerConnection>
...
</scm>
{code}
so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
was:
as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
Ideally if pushChanges is false, it should use a value of
{code}
<release-altGitURL>scm:git:file://${baseDir}</release-altGitURL>
{code}
so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: http://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Closed: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "Mark Struberg (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mark Struberg closed MRELEASE-605.
----------------------------------
Resolution: Won't Fix
Assignee: Mark Struberg
Hi James!
The issue appears to be invalid. Please use <localCheckout>true if you configure <pushChanges>false.
This will make the git clone to happen from a local file:// instead of using the upstream git:// URL.
Please note that localCheckout currently only works with non-sparse checkouts! We are working on that in the next release.
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: https://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
> Assignee: Mark Struberg
> Fix For: 2.2
>
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "Toni Menzel (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=248786#action_248786 ]
Toni Menzel commented on MRELEASE-605:
--------------------------------------
Any chance seeing pushChanges=false work out of the box without the "-DconnectionUrl=scm:git:file:///directory/where/my/code/is" workaround in 2.2 ?
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: http://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
> Fix For: 2.2
>
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MRELEASE-605) when not pushing changes to remote
git repo in 2.1, the release plugin fails on release:perform
Posted by "james strachan (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/MRELEASE-605?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=274346#comment-274346 ]
james strachan commented on MRELEASE-605:
-----------------------------------------
Just wanted to say a big thank you! Works like a charm. Its made one geek very happy :). Just did a release without having to muck about with connectionUrl - yay!
> when not pushing changes to remote git repo in 2.1, the release plugin fails on release:perform
> -----------------------------------------------------------------------------------------------
>
> Key: MRELEASE-605
> URL: https://jira.codehaus.org/browse/MRELEASE-605
> Project: Maven 2.x Release Plugin
> Issue Type: Improvement
> Affects Versions: 2.1
> Reporter: james strachan
> Assignee: Mark Struberg
> Fix For: 2.2
>
>
> as it tries to clone the remote repo, which has not yet been pushed - so there's no tag in the remote repo yet.
> Ideally if pushChanges is false, it should use a value of
> {code}
> <scm>
> <developerConnectionL>scm:git:file://${baseDir}</developerConnection>
> ...
> </scm>
> {code}
> so that it clones from the current local git repo (which has everything inside it) rather than the remote repo which has yet to be pushed.
> BTW a great use case for not pushing is using a staging maven repo like Nexus; which may reject an attempt to promote a staged build, so you only want to push after a downstream stage works.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira