[ http://jira.codehaus.org/browse/MRELEASE-131?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_89463 ]
Peter De Velder commented on MRELEASE-131: ------------------------------------------ Same problem, tested this out in cvs (1.11.1p1), 1) Problem reproduced when using option: -d MYCVSROOT, 2) No more problem without option: -d MYCVSROOT ~/maven_parent> cvs -nq update -d M pom.xml M child1/pom.xml M child2/pom.xml #--------------------------------------------------------------------------- # Problem: parent pom.xml is not committed, together with the child poms #--------------------------------------------------------------------------- ~/maven_parent> cvs -d :pserver:[EMAIL PROTECTED]:/home/cvs/play commit -m "test" pom.xml child1/pom.xml child2/pom.xml Checking in admin_focus/pom.xml; /home/cvs/play/maven_parent/child1/pom.xml,v <-- pom.xml new revision: 1.81; previous revision: 1.80 done Checking in focus_core/pom.xml; /home/cvs/play/maven_parent/child1/pom.xml,v <-- pom.xml new revision: 1.74; previous revision: 1.73 done #--------------------------------------------------------------------------- # Problem fixed: No longer using -d option #--------------------------------------------------------------------------- ~/maven_parent> cvs commit -m "test" pom.xml child1/pom.xml child2/pom.xml Checking in pom.xml; /home/cvs/play/maven_parent/pom.xml,v <-- pom.xml new revision: 1.30; previous revision: 1.29 done Checking in admin_focus/pom.xml; /home/cvs/play/maven_parent/child1/pom.xml,v <-- pom.xml new revision: 1.82; previous revision: 1.81 done Checking in focus_core/pom.xml; /home/cvs/play/maven_parent/child2/pom.xml,v <-- pom.xml new revision: 1.75; previous revision: 1.74 done > release:prepare failed in 'cvs ... commit' phase for multi-module build > ----------------------------------------------------------------------- > > Key: MRELEASE-131 > URL: http://jira.codehaus.org/browse/MRELEASE-131 > Project: Maven 2.x Release Plugin > Issue Type: Bug > Affects Versions: 2.0-beta-4 > Environment: redhat linux, cvs 1.11.17, maven 2.0.4 > Reporter: Hung Le > > I have a multi-module setup > parent-module > child-module-1 > child-module-2 > ... > In CVS, they are peer, to establish the parent-child layout, manually first > check out > . parent-module (which has only the pom.xml) > then 'cd to parent-module' and manually check out each of the child > module (using 'cvs co -d outputDir module_name) > when I use 'release:prepare', Maven2 failed at the 'commit phase'. After > playing with the 'cvs commit ...' it appears that changing the order the > 'list of modified POM's' gives different results. One that allow an OK > 'commit' involves ordering the list of the modified POM's so that the parent > POM is first in the list. > It does look as if this is a cvs-specific issue but if we can do something to > help as work-around, that will be great. I did quick experiment by modifying > ScmCommitPhase.java. In method createPomFiles(reactorProjects), sort the list > before returning and it did let me complete the release:prepare step: > // [EMAIL PROTECTED] > System.out.println("preSorted, pomFiles=" + pomFiles); > boolean sortPomFiles = true; > if (sortPomFiles) { > Comparator comp = new Comparator() { > public int compare(Object o1, Object o2) { > File f1 = (File) o1; > File f2 = (File) o2; > String str1 = f1.getAbsolutePath(); > String str2 = f2.getAbsolutePath(); > int rv = (str1.length() - str2.length()); > if (rv == 0) { > rv = f1.compareTo(f2); > } > return rv; > } > }; > Collections.sort(pomFiles, comp); > } > System.out.println("postSorted, pomFiles=" + pomFiles); -- 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