Maven Release Plugin
  1. Maven Release Plugin
  2. MRELEASE-812

"prepare" does not commit before tagging and therefore deploys snapshot instead of release

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 2.3.2, 2.4
    • Fix Version/s: 2.5
    • Component/s: Git
    • Labels:
      None

      Description

      thank you very much for new release!
      http://mail-archives.apache.org/mod_mbox/maven-announce/201212.mbox/%3Cop.wpjbptp1kdkhrr@columbia%3E

      it seems we need an emergency fix:

      attached are 2 logs:
      1) mvn-2.3.2.txt invocation that works fine with 2.3.2
      2) mvn-2.4.0.txt invocation that fails with 2.4

      problem:

      "perform" does not commit tags, deploys snapshot instead of release

      here is project parent:
      http://search.maven.org/remotecontent?filepath=com/barchart/base/barchart-archon/2.3.6/barchart-archon-2.3.6.pom

      build is invoked both times with this:

      mvn --define resume=false release:prepare
      mvn --define resume=false release:perform

      1. mvn-2.3.2.txt
        25 kB
      2. mvn-2.4.0.txt
        27 kB

        Issue Links

          Activity

          Hide
          Koen Serneels added a comment - - edited

          I was experiencing the same issue (Git 1.9.1/Ubuntu). The release plugin (was using 2.4.2) would not commit anymore, resulting in the SNAPSHOT suffix being present in the tag.
          Bumping the release plugin to 2.5 solved the problem for projects having the pom.xml in the repository root.
          However, I had another project with the pom.xml NOT directly in the repository root. For this bumping to 2.5 alone was not enough. To fix this the SCM api and gitexe dependency also need to be overridden to the latest version (1.9.1 atm). This solved the problem there as well with the release plugin still at v2.5

          <dependencies>
          	<dependency>
                      <groupId>org.apache.maven.scm</groupId>
                      <artifactId>maven-scm-api</artifactId>
                      <version>1.9.1</version>
                  </dependency>
                  <dependency>
                      <groupId>org.apache.maven.scm</groupId>
                      <artifactId>maven-scm-provider-gitexe</artifactId>
                      <version>1.9.1</version>
                  </dependency>
          </dependencies>
          

          See also https://jira.codehaus.org/browse/SCM-740

          Show
          Koen Serneels added a comment - - edited I was experiencing the same issue (Git 1.9.1/Ubuntu). The release plugin (was using 2.4.2) would not commit anymore, resulting in the SNAPSHOT suffix being present in the tag. Bumping the release plugin to 2.5 solved the problem for projects having the pom.xml in the repository root. However, I had another project with the pom.xml NOT directly in the repository root. For this bumping to 2.5 alone was not enough. To fix this the SCM api and gitexe dependency also need to be overridden to the latest version (1.9.1 atm). This solved the problem there as well with the release plugin still at v2.5 <dependencies> <dependency> <groupId>org.apache.maven.scm</groupId> <artifactId>maven-scm-api</artifactId> <version>1.9.1</version> </dependency> <dependency> <groupId>org.apache.maven.scm</groupId> <artifactId>maven-scm-provider-gitexe</artifactId> <version>1.9.1</version> </dependency> </dependencies> See also https://jira.codehaus.org/browse/SCM-740
          Hide
          Torben Knerr added a comment -

          Re: 2.5 solved the problem only for projects with top-level pom files, run into MRELEASE-875 as well :-/

          I tried switching back to 2.4.2 or 2.3.2 but none of the suggested approaches worked for me (neither with LANG=en_US.UTF8 nor with the git-exe 1.9 plugin dependency)

          Show
          Torben Knerr added a comment - Re: 2.5 solved the problem only for projects with top-level pom files, run into MRELEASE-875 as well :-/ I tried switching back to 2.4.2 or 2.3.2 but none of the suggested approaches worked for me (neither with LANG=en_US.UTF8 nor with the git-exe 1.9 plugin dependency)
          Hide
          Torben Knerr added a comment -

          Interestingly, I'm seeing this with maven-3.0.5 / maven-release-plugin 2.4.2 on our build server (ubuntu) but not on my local windows machine (windows).

          I had run exactly the same commands (mvn release:clean release:prepare -B -X -DreleaseVersion=1.0-alpha-1 -DupdateWorkingCopyVersions=false) on both my windows workstation and on our ubuntu buildserver.

          They produced exactly the same output, same plugin dependencies (run with -X flag), but on the buildserver the commit / push of the modified pom was missing.

          I have no clue why this behaves differently on my windows workstation vs. buildserver.

          Pinning maven-release-plugin to 2.5 in pluginManagement solved the problem for me.

          Show
          Torben Knerr added a comment - Interestingly, I'm seeing this with maven-3.0.5 / maven-release-plugin 2.4.2 on our build server (ubuntu) but not on my local windows machine (windows). I had run exactly the same commands ( mvn release:clean release:prepare -B -X -DreleaseVersion=1.0-alpha-1 -DupdateWorkingCopyVersions=false ) on both my windows workstation and on our ubuntu buildserver. They produced exactly the same output, same plugin dependencies (run with -X flag), but on the buildserver the commit / push of the modified pom was missing. I have no clue why this behaves differently on my windows workstation vs. buildserver. Pinning maven-release-plugin to 2.5 in pluginManagement solved the problem for me.
          Hide
          Martin Ellis added a comment -

          Looks like we're seeing MRELEASE-875.
          I've added my vote there.

          Show
          Martin Ellis added a comment - Looks like we're seeing MRELEASE-875 . I've added my vote there.
          Hide
          AF KL Customer added a comment -

          We have exactly the same problem with maven-release-plugin 2.5 (but only with projects which don't have a pom at the root of git repository) . For projects with a pom at the root , it works fine !

          Show
          AF KL Customer added a comment - We have exactly the same problem with maven-release-plugin 2.5 (but only with projects which don't have a pom at the root of git repository) . For projects with a pom at the root , it works fine !
          Hide
          Martin Ellis added a comment -

          Just experienced this bug with maven-release-plugin 2.5 using git.
          Reverting to 2.4.2 fixes the behaviour for me (i.e. commits the pom with a release version).

          Show
          Martin Ellis added a comment - Just experienced this bug with maven-release-plugin 2.5 using git. Reverting to 2.4.2 fixes the behaviour for me (i.e. commits the pom with a release version).
          Hide
          Aleksandr Tarutin added a comment -

          I run into an issue where release:prepare would commit and push -SNAPSHOT into the tag. Fortunately, the solution with maven-scm-provider-gitexe above fixed it.

          Thank you,

          AT.

          Show
          Aleksandr Tarutin added a comment - I run into an issue where release:prepare would commit and push -SNAPSHOT into the tag. Fortunately, the solution with maven-scm-provider-gitexe above fixed it. Thank you, AT.
          Hide
          John Casey added a comment - - edited

          I've seen this happening in version 2.3.2 also.

          I'm just adding this to help others searching for solutions to this. It's a VERY difficult problem to understand until you sift through the debug console output...and even then, you have to know what to look for.

          If you're using Maven 3.1.1, this behavior will crop up if you don't have a version specified for the release plugin in your pom.xml, since it seems to be the default version.

          From an execution using Maven 3.1.1 and release 2.3.2:

          [DEBUG] On branch master
          [DEBUG] Your branch is up-to-date with 'origin/master'.
          [DEBUG] 
          [DEBUG] Changes to be committed:
          [DEBUG]   (use "git reset HEAD <file>..." to unstage)
          [DEBUG] 
          [DEBUG] 	modified:   pom.xml
          [DEBUG] 
          [DEBUG] Untracked files:
          [DEBUG]   (use "git add <file>..." to include in what will be committed)
          [DEBUG] 
          [DEBUG] 	pom.xml.releaseBackup
          [DEBUG] 	prepare.log
          [DEBUG] 	release.properties
          [DEBUG] 
          [INFO] Tagging release with the label buildmetadata-maven-plugin-1.3.1...
          
          Show
          John Casey added a comment - - edited I've seen this happening in version 2.3.2 also. I'm just adding this to help others searching for solutions to this. It's a VERY difficult problem to understand until you sift through the debug console output...and even then, you have to know what to look for. If you're using Maven 3.1.1, this behavior will crop up if you don't have a version specified for the release plugin in your pom.xml, since it seems to be the default version. From an execution using Maven 3.1.1 and release 2.3.2: [DEBUG] On branch master [DEBUG] Your branch is up-to-date with 'origin/master'. [DEBUG] [DEBUG] Changes to be committed: [DEBUG] (use "git reset HEAD <file>..." to unstage) [DEBUG] [DEBUG] modified: pom.xml [DEBUG] [DEBUG] Untracked files: [DEBUG] (use "git add <file>..." to include in what will be committed) [DEBUG] [DEBUG] pom.xml.releaseBackup [DEBUG] prepare.log [DEBUG] release.properties [DEBUG] [INFO] Tagging release with the label buildmetadata-maven-plugin-1.3.1...
          Hide
          Jan Novotný added a comment -

          You can also run into the issues with deep folder structure here - another bug filled is here #MRELEASE-864
          Details here: http://blog.novoj.net/2014/01/24/maven-release-plugin-releases-snapshot-instead-of-stable-version/

          Show
          Jan Novotný added a comment - You can also run into the issues with deep folder structure here - another bug filled is here #MRELEASE-864 Details here: http://blog.novoj.net/2014/01/24/maven-release-plugin-releases-snapshot-instead-of-stable-version/
          Hide
          James Ward added a comment -

          I just hit this as well. A release fix would be greatly appreciated since it will be easier to bump the maven-release-plugin than to add the new dependency to 250 WebJar projects.

          Show
          James Ward added a comment - I just hit this as well. A release fix would be greatly appreciated since it will be easier to bump the maven-release-plugin than to add the new dependency to 250 WebJar projects.
          Hide
          Robert Scholte added a comment -

          Paul Millar, you don't have to wait for a release, you can use it already now if you want. Just add the required dependencies to the maven-release-plugin:

          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-release-plugin</artifactId>
            <version>2.4.2</version>
            <dependencies>
              <dependency>
                <groupId>org.apache.maven.scm</groupId>
                <artifactId>maven-scm-provider-gitexe</artifactId>
                <version>1.9</version>
              </dependency>
            </dependencies>
          </plugin>
          
          Show
          Robert Scholte added a comment - Paul Millar , you don't have to wait for a release, you can use it already now if you want. Just add the required dependencies to the maven-release-plugin: <plugin> <groupId> org.apache.maven.plugins </groupId> <artifactId> maven-release-plugin </artifactId> <version> 2.4.2 </version> <dependencies> <dependency> <groupId> org.apache.maven.scm </groupId> <artifactId> maven-scm-provider-gitexe </artifactId> <version> 1.9 </version> </dependency> </dependencies> </plugin>
          Hide
          Paul Millar added a comment -

          Sorry for the noob question, but when will 2.5 be released?

          This link doesn't seem to contain any release schedule information (or link to any such information).

          As the 2.5 contains critical bug-fixes, a timely release would be useful.

          Show
          Paul Millar added a comment - Sorry for the noob question, but when will 2.5 be released? This link doesn't seem to contain any release schedule information (or link to any such information). As the 2.5 contains critical bug-fixes, a timely release would be useful.
          Hide
          Robert Scholte added a comment -

          Fixed by MRELEASE-862

          Show
          Robert Scholte added a comment - Fixed by MRELEASE-862
          Hide
          Robert Scholte added a comment -

          There's a call for vote for SCM 1.9 at this moment. If the vote succeeds, it'll probably be available this weekend.

          Show
          Robert Scholte added a comment - There's a call for vote for SCM 1.9 at this moment. If the vote succeeds, it'll probably be available this weekend.
          Hide
          Paul Millar added a comment -

          Hit this problem myself (or one like it). The trigger seems to be an upgrade of git from 1.8.5.1 to 1.8.5.2, but I'm still double-checking that.

          I tried the above work-around posted by Catalin (updating maven-scm version dependency to 1.8.1) but encountered the problem described in SCM 709: support for sub-projects/modules is broken.

          Is there a way to test SCM 686 and SCM 709 together; e.g., a snapshot or nightly release of maven-scm I could add as a dependency instead of 1.8.1?

          In SCM 709, they cite a lack of feedback as a reason why progress isn't being made, but it's unclear to me how they expect to receive this feedback if the patch isn't available for testing somewhere.

          Show
          Paul Millar added a comment - Hit this problem myself (or one like it). The trigger seems to be an upgrade of git from 1.8.5.1 to 1.8.5.2, but I'm still double-checking that. I tried the above work-around posted by Catalin (updating maven-scm version dependency to 1.8.1) but encountered the problem described in SCM 709: support for sub-projects/modules is broken. Is there a way to test SCM 686 and SCM 709 together; e.g., a snapshot or nightly release of maven-scm I could add as a dependency instead of 1.8.1? In SCM 709, they cite a lack of feedback as a reason why progress isn't being made, but it's unclear to me how they expect to receive this feedback if the patch isn't available for testing somewhere.
          Hide
          Robert Scholte added a comment -

          Current status: SCM-686 was an attempt to fix this, but it did more harm than good. Projects which weren't located at the root of the project couldn't be released. SCM-709 should fix this. It is probably fixed with the current snapshot of the SCM project, but there's still no good feedback.

          Show
          Robert Scholte added a comment - Current status: SCM-686 was an attempt to fix this, but it did more harm than good. Projects which weren't located at the root of the project couldn't be released. SCM-709 should fix this. It is probably fixed with the current snapshot of the SCM project, but there's still no good feedback.
          Hide
          Jeremie H added a comment -

          @Catalin Patruica
          Yes, setting the system language to English worked. But I strongly agree with Richard Eckart de Castilho : the plugin should work regardless of the system language.

          Show
          Jeremie H added a comment - @Catalin Patruica Yes, setting the system language to English worked. But I strongly agree with Richard Eckart de Castilho : the plugin should work regardless of the system language.
          Hide
          Richard Eckart de Castilho added a comment - - edited

          Last time I checked, it was necessary to change the system language to English for releases to work.

          In any case, I think this should only be closed when/if the maven-release-plugin itself chooses providers that work. The user should not need to manually upgrade dependencies of a plugin for it to work.

          Show
          Richard Eckart de Castilho added a comment - - edited Last time I checked, it was necessary to change the system language to English for releases to work. In any case, I think this should only be closed when/if the maven-release-plugin itself chooses providers that work. The user should not need to manually upgrade dependencies of a plugin for it to work.
          Hide
          Catalin Patruica added a comment -

          @Jeremie H
          has the solution work for you or you are still having problems?
          because if it has work, then the issue can be close, right?

          ceers,
          cp

          Show
          Catalin Patruica added a comment - @Jeremie H has the solution work for you or you are still having problems? because if it has work, then the issue can be close, right? ceers, cp
          Hide
          Jeremie H added a comment -

          I lost so mush time on this...

          Show
          Jeremie H added a comment - I lost so mush time on this...
          Hide
          Catalin Patruica added a comment -

          I had the same problems but after some hours of search i was finding a sollution that was working for me:
          just add the dependencies of the maven-release-plugin
          <dependencies>
          <dependency>
          <groupId>org.apache.maven.scm</groupId>
          <artifactId>maven-scm-api</artifactId>
          <version>1.8.1</version>
          </dependency>
          <dependency>
          <groupId>org.apache.maven.scm</groupId>
          <artifactId>maven-scm-provider-gitexe</artifactId>
          <version>1.8.1</version>
          </dependency>
          </dependencies>

          for testing I have created a test project on github
          https://github.com/duderoot/maven.release.plugin
          and also make a more detailed description under
          http://xlab-iq.blogspot.de/2013/10/maven-release-plugin.html
          I hope it helps.
          cheers,
          cp

          Show
          Catalin Patruica added a comment - I had the same problems but after some hours of search i was finding a sollution that was working for me: just add the dependencies of the maven-release-plugin <dependencies> <dependency> <groupId>org.apache.maven.scm</groupId> <artifactId>maven-scm-api</artifactId> <version>1.8.1</version> </dependency> <dependency> <groupId>org.apache.maven.scm</groupId> <artifactId>maven-scm-provider-gitexe</artifactId> <version>1.8.1</version> </dependency> </dependencies> for testing I have created a test project on github https://github.com/duderoot/maven.release.plugin and also make a more detailed description under http://xlab-iq.blogspot.de/2013/10/maven-release-plugin.html I hope it helps. cheers, cp
          Hide
          Stefan Fleiter added a comment -

          Stumbled upon this and wasted several hours on it.
          Wanting to report the bug I see this one, known for far too long.
          What a shame!

          Show
          Stefan Fleiter added a comment - Stumbled upon this and wasted several hours on it. Wanting to report the bug I see this one, known for far too long. What a shame!
          Hide
          Christoph Kutzinski added a comment -

          SCM-686 is fixed for several months, but still not included in the release-plugin.
          When will this finally be fixed? IMO it's really critical.

          Show
          Christoph Kutzinski added a comment - SCM-686 is fixed for several months, but still not included in the release-plugin. When will this finally be fixed? IMO it's really critical.
          Hide
          Christoph Kutzinski added a comment -

          Contrary to other comments here I had the same problem with maven-release-plugin 2.3.2. The workaround described here http://www.shredzone.de/cilla/page/373/maven-release-plugin-and-git-fix.html - i.e. setting LANG to english - worked.

          Show
          Christoph Kutzinski added a comment - Contrary to other comments here I had the same problem with maven-release-plugin 2.3.2. The workaround described here http://www.shredzone.de/cilla/page/373/maven-release-plugin-and-git-fix.html - i.e. setting LANG to english - worked.
          Show
          Andrei Pozolotin added a comment - Robert: thank you for looking into this; here is a test case: 1) repo to clone https://github.com/barchart/barchart-bugs 2) project with v 2.3.2, which works https://github.com/barchart/barchart-bugs/tree/master/barchart-bugs-MRELEASE-812/build-tester/barchart-bugs-MRELEASE-812-case-01 and maven log https://raw.github.com/barchart/barchart-bugs/master/barchart-bugs-MRELEASE-812/build-tester/barchart-bugs-MRELEASE-812-case-01/doc/mvn.log.txt run from eclipse: https://github.com/barchart/barchart-bugs/blob/master/barchart-bugs-MRELEASE-812/build-tester/barchart-bugs-MRELEASE-812-case-01/build/maven-release.ant 3) project with v 2.4, which is broken https://github.com/barchart/barchart-bugs/tree/master/barchart-bugs-MRELEASE-812/build-tester/barchart-bugs-MRELEASE-812-case-02 and maven log https://raw.github.com/barchart/barchart-bugs/master/barchart-bugs-MRELEASE-812/build-tester/barchart-bugs-MRELEASE-812-case-02/doc/mvn.log.txt run from eclipse: https://github.com/barchart/barchart-bugs/blob/master/barchart-bugs-MRELEASE-812/build-tester/barchart-bugs-MRELEASE-812-case-02/build/maven-release.ant thank you. Andrei.
          Hide
          Robert Scholte added a comment -

          It has probably to do with SCM-686, so I'm thinking that the GIT-version could be an issue.
          Fred Cooke is using git 1.7.10.4

          It looks like the result of Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status --porcelain isn't parsed correctly.
          Anyhow, this should be solved at https://jira.codehaus.org/browse/SCM
          Would be nice if you could create an issue there with the GIT version and the result of the git status --porcelain

          Once fixed and released, the plugin needs that version of the maven-scm-api

          Show
          Robert Scholte added a comment - It has probably to do with SCM-686 , so I'm thinking that the GIT-version could be an issue. Fred Cooke is using git 1.7.10.4 It looks like the result of Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status --porcelain isn't parsed correctly. Anyhow, this should be solved at https://jira.codehaus.org/browse/SCM Would be nice if you could create an issue there with the GIT version and the result of the git status --porcelain Once fixed and released, the plugin needs that version of the maven-scm-api
          Hide
          Robert Scholte added a comment -

          Based on the logs I see the following differences:

          maven-release-plugin:2.3.2
          [INFO] Checking in modified POMs...
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git add -- pom.xml
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git commit --verbose -F /tmp/maven-scm-886620709.commit pom.xml
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git symbolic-ref HEAD
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git push ssh://git@github.com/barchart/barchart-libraries.git master:master
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Tagging release with the label barchart-build-test-1-1.0.14...
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git tag -F /tmp/maven-scm-2056845372.commit barchart-build-test-1-1.0.14
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git push ssh://git@github.com/barchart/barchart-libraries.git barchart-build-test-1-1.0.14
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git ls-files
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Transforming 'barchart-build-test-1'...
          [INFO] Not removing release POMs
          [INFO] Checking in modified POMs...
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git add -- pom.xml
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git commit --verbose -F /tmp/maven-scm-839755101.commit pom.xml
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git symbolic-ref HEAD
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git push ssh://git@github.com/barchart/barchart-libraries.git master:master
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Release preparation complete.
          
          maven-release-plugin:2.4
          [INFO] Checking in modified POMs...
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git add -- pom.xml
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status --porcelain
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Tagging release with the label barchart-build-test-1-1.0.13...
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git tag -F /tmp/maven-scm-1489330697.commit barchart-build-test-1-1.0.13
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git push ssh://git@github.com/barchart/barchart-libraries.git barchart-build-test-1-1.0.13
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git ls-files
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Transforming 'barchart-build-test-1'...
          [INFO] Not removing release POMs
          [INFO] Checking in modified POMs...
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git add -- pom.xml
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status --porcelain
          [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1
          [INFO] Release preparation complete.
          
          Show
          Robert Scholte added a comment - Based on the logs I see the following differences: maven-release-plugin:2.3.2 [INFO] Checking in modified POMs... [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git add -- pom.xml [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git commit --verbose -F /tmp/maven-scm-886620709.commit pom.xml [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git symbolic-ref HEAD [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git push ssh://git@github.com/barchart/barchart-libraries.git master:master [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Tagging release with the label barchart-build-test-1-1.0.14... [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git tag -F /tmp/maven-scm-2056845372.commit barchart-build-test-1-1.0.14 [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git push ssh://git@github.com/barchart/barchart-libraries.git barchart-build-test-1-1.0.14 [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git ls-files [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Transforming 'barchart-build-test-1'... [INFO] Not removing release POMs [INFO] Checking in modified POMs... [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git add -- pom.xml [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git commit --verbose -F /tmp/maven-scm-839755101.commit pom.xml [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git symbolic-ref HEAD [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git push ssh://git@github.com/barchart/barchart-libraries.git master:master [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Release preparation complete. maven-release-plugin:2.4 [INFO] Checking in modified POMs... [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git add -- pom.xml [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status --porcelain [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Tagging release with the label barchart-build-test-1-1.0.13... [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git tag -F /tmp/maven-scm-1489330697.commit barchart-build-test-1-1.0.13 [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git push ssh://git@github.com/barchart/barchart-libraries.git barchart-build-test-1-1.0.13 [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git ls-files [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Transforming 'barchart-build-test-1'... [INFO] Not removing release POMs [INFO] Checking in modified POMs... [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git add -- pom.xml [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Executing: /bin/sh -c cd /work/git/barchart-libraries/build-tester/barchart-build-test-1 && git status --porcelain [INFO] Working directory: /work/git/barchart-libraries/build-tester/barchart-build-test-1 [INFO] Release preparation complete.
          Hide
          Fred Cooke added a comment -

          I just tried to reproduce this behaviour on a simple git-maven project locally and couldn't:

          commit c658aaec37369f040ba77deb05382bbe5284ee1c
          Author: Fred Cooke <email>
          Date:   Thu Jan 3 10:46:21 2013 +0100
          
              Update to 2.4 to assist testing MRELEASE-812.
          
          diff --git a/pom.xml b/pom.xml
          index ec5cfe2..9271b8d 100644
          --- a/pom.xml
          +++ b/pom.xml
          @@ -49,7 +49,7 @@
          -               <plugin.version.release>2.3.2</plugin.version.release>
          +               <plugin.version.release>2.4</plugin.version.release>
          
          [INFO] --- maven-release-plugin:2.4:prepare (default-cli) @ parent ---
          
          fred@dauntless:~/workspace/parent$ git show 0.4
          tag 0.4
          Tagger: Fred Cooke <email>
          Date:   Thu Jan 3 10:47:08 2013 +0100
          
          [maven-release-plugin]  copy for tag 0.4
          
          commit bf9e44d196c5735cb4fc585ed33e76496064f2a4
          Author: Fred Cooke <email>
          Date:   Thu Jan 3 10:47:08 2013 +0100
          
              [maven-release-plugin] prepare release 0.4
          
          diff --git a/pom.xml b/pom.xml
          index 9271b8d..d413c19 100644
          --- a/pom.xml
          +++ b/pom.xml
          @@ -3,7 +3,7 @@
           
                  <groupId>com.?</groupId>
                  <artifactId>parent</artifactId>
          -       <version>0.4-SNAPSHOT</version>
          +       <version>0.4</version>
                  <packaging>pom</packaging>
           
                  <name>Parent Project</name>
          @@ -16,7 +16,7 @@
           
                  <scm>
                          <developerConnection>scm:git:?:parent.git</developerConnection>
          -               <tag>HEAD</tag>
          +               <tag>0.4</tag>
                  </scm>
           
                  <distributionManagement>
          
          
          Show
          Fred Cooke added a comment - I just tried to reproduce this behaviour on a simple git-maven project locally and couldn't: commit c658aaec37369f040ba77deb05382bbe5284ee1c Author: Fred Cooke <email> Date: Thu Jan 3 10:46:21 2013 +0100 Update to 2.4 to assist testing MRELEASE-812. diff --git a/pom.xml b/pom.xml index ec5cfe2..9271b8d 100644 --- a/pom.xml +++ b/pom.xml @@ -49,7 +49,7 @@ - <plugin.version.release>2.3.2</plugin.version.release> + <plugin.version.release>2.4</plugin.version.release> [INFO] --- maven-release-plugin:2.4:prepare (default-cli) @ parent --- fred@dauntless:~/workspace/parent$ git show 0.4 tag 0.4 Tagger: Fred Cooke <email> Date: Thu Jan 3 10:47:08 2013 +0100 [maven-release-plugin] copy for tag 0.4 commit bf9e44d196c5735cb4fc585ed33e76496064f2a4 Author: Fred Cooke <email> Date: Thu Jan 3 10:47:08 2013 +0100 [maven-release-plugin] prepare release 0.4 diff --git a/pom.xml b/pom.xml index 9271b8d..d413c19 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ <groupId>com.?</groupId> <artifactId>parent</artifactId> - <version>0.4-SNAPSHOT</version> + <version>0.4</version> <packaging>pom</packaging> <name>Parent Project</name> @@ -16,7 +16,7 @@ <scm> <developerConnection>scm:git:?:parent.git</developerConnection> - <tag>HEAD</tag> + <tag>0.4</tag> </scm> <distributionManagement>
          Hide
          Fred Cooke added a comment -

          Additionally, in git a tag is not a commit as such, it's a label on an existing commit. So:

          "perform" does not commit tags, deploys snapshot instead of release

          Should be changed to

          "prepare" does not commit before tagging and therefore deploys snapshot instead of release, as this is what the tag points at.

          Show
          Fred Cooke added a comment - Additionally, in git a tag is not a commit as such, it's a label on an existing commit. So: "perform" does not commit tags, deploys snapshot instead of release Should be changed to "prepare" does not commit before tagging and therefore deploys snapshot instead of release, as this is what the tag points at.
          Hide
          Robert Scholte added a comment - - edited

          "perform" does not commit tags, deploys snapshot instead of release

          It's the prepare which does the commits, never the perform.

          Since the tests run with the release-version during the prepare it's not a transformation issue.
          So it looks more like a GIT-specific issue. Could it be an issue with SCM-1.8? Could you try to use the 1.7 dependencies?

                  <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>2.4</version>
                    <dependencies>
                      <dependency>
                        <groupId>org.apache.maven.scm</groupId>
                        <artifactId>maven-scm-api</artifactId>
                        <version>1.7</version>
                      </dependency>
                    </dependencies>
                  </plugin>
          
          Show
          Robert Scholte added a comment - - edited "perform" does not commit tags, deploys snapshot instead of release It's the prepare which does the commits, never the perform . Since the tests run with the release-version during the prepare it's not a transformation issue. So it looks more like a GIT-specific issue. Could it be an issue with SCM-1 .8? Could you try to use the 1.7 dependencies? <plugin> <groupId> org.apache.maven.plugins </groupId> <artifactId> maven-release-plugin </artifactId> <version> 2.4 </version> <dependencies> <dependency> <groupId> org.apache.maven.scm </groupId> <artifactId> maven-scm-api </artifactId> <version> 1.7 </version> </dependency> </dependencies> </plugin>

            People

            • Assignee:
              Robert Scholte
              Reporter:
              Andrei Pozolotin
            • Votes:
              13 Vote for this issue
              Watchers:
              27 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development