jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • Maven SCM
  • SCM-488

Git provider fails to support 'release:perform' if not releasing from remote HEAD

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: None
  • Fix Version/s: 1.3
  • Component/s: maven-scm-provider-git
  • Labels:
    None
  • Complexity:
    Intermediate

Description

During the 'release:perform' phase using Git provider the following commands are issued:

[INFO] Checking out the project to perform the release ...
[INFO] Executing: /bin/sh -c cd /Users/pettermahlen/git/sas-client/target && git clone git://git.shopzilla.com/site/client/sas-client /Users/pettermahlen/git/sas-client/target/checkout
[INFO] Working directory: /Users/pettermahlen/git/sas-client/target
[INFO] Executing: /bin/sh -c cd /Users/pettermahlen/git/sas-client/target/checkout && git pull git://git.shopzilla.com/site/client/sas-client tag root-5.18-uk
[INFO] Working directory: /Users/pettermahlen/git/sas-client/target/checkout

If the branch that is being released has conflicts (that cannot be automatically resolved) with the current HEAD at the remote server, the 'pull' with fail due to merge conflicts. A manual execution can look like:

[pettermahlen@Petters-MacBook-Pro target (uk-release)]$ git clone git://git.shopzilla.com/site/client/sas-client /Users/pettermahlen/git/sas-client/target/checkout
Initialized empty Git repository in /Users/pettermahlen/git/sas-client/target/checkout/.git/
remote: Counting objects: 72993, done.
remote: Compressing objects: 100% (18392/18392), done.
remote: Total 72993 (delta 40752), reused 71454 (delta 39845)
Receiving objects: 100% (72993/72993), 38.22 MiB | 2724 KiB/s, done.
Resolving deltas: 100% (40752/40752), done.
[pettermahlen@Petters-MacBook-Pro target (uk-release)]$ cd checkout/
[pettermahlen@Petters-MacBook-Pro checkout (master)]$ git pull git://git.shopzilla.com/site/client/sas-client tag root-5.18-uk
Auto-merging client/pom.xml
CONFLICT (content): Merge conflict in client/pom.xml
Auto-merging core/pom.xml
CONFLICT (content): Merge conflict in core/pom.xml
Auto-merging model/pom.xml

Pull does a fetch and a merge with what is currently checked out. A potential fix would be to rather than the 'git pull' command issue the following:

git checkout <scm.tag>

That's what I did to get past this situation, and I believe that should work as a general solution.

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
Mark Struberg added a comment - 08/Oct/09 7:41 AM

fixed in Revision 823147

Show
Mark Struberg added a comment - 08/Oct/09 7:41 AM fixed in Revision 823147
Hide
Permalink
Damon Rand added a comment - 04/May/10 7:13 PM

I'm trying to get access to this fix but mvn is using maven-scm-provider-gitexe v1.1. I can't work out how to force it to use 1.3 in my pom.xml?

Show
Damon Rand added a comment - 04/May/10 7:13 PM I'm trying to get access to this fix but mvn is using maven-scm-provider-gitexe v1.1. I can't work out how to force it to use 1.3 in my pom.xml?
Hide
Permalink
Mark Struberg added a comment - 05/May/10 1:08 AM

Damon, which maven version are you using?
Try running
$> mvn -X release:help | less
and search for 'gitexe'

Then try upgrading to a newer maven version. Either > 2.0.11, 2.2.1 or 3.0-beta-1 should do the job.

Show
Mark Struberg added a comment - 05/May/10 1:08 AM Damon, which maven version are you using? Try running $> mvn -X release:help | less and search for 'gitexe' Then try upgrading to a newer maven version. Either > 2.0.11, 2.2.1 or 3.0-beta-1 should do the job.

People

  • Assignee:
    Mark Struberg
    Reporter:
    Petter Måhlén
Vote (0)
Watch (1)

Dates

  • Created:
    03/Aug/09 7:01 AM
    Updated:
    05/May/10 1:08 AM
    Resolved:
    08/Oct/09 7:41 AM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.