Uploaded image for project: 'Maven SCM'
  1. Maven SCM
  2. SCM-427

HgUpdateCommand

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Won't Fix
    • Affects Version/s: 1.1
    • Fix Version/s: None
    • Labels:
      None
    • Environment:

      Description

      In HgUpdateCommand.java the following steps are performed

      hg pull -r tip
      hg id
      hg diff -r -1
      hg log --verbose

      Firstly, the working copies of the files are never updated by any of these commands, only the local repository is updated..

      This can be verified using the following test:

      $mvn -Ptck -Dtest=HgUpdateCommandTckTest test

      -------------------------------------------------------
      T E S T S
      -------------------------------------------------------
      Running org.apache.maven.scm.provider.hg.command.update.HgUpdateCommandTckTest
      EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch && hg init
      EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch && hg add /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch/pom.xml /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch/readme.txt /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch/src/main/java/Application.java /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch/src/test/java/Test.java
      EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch && hg commit --message 'Add files to test branch'
      [INFO] Removing /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test && hg clone -r tip /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy && hg locate
      [INFO] Removing /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/updating-copy
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test && hg clone -r tip /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/updating-copy
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/updating-copy && hg locate
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy && hg add --verbose project.xml
      [INFO] [project.xml:added]
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy && hg add --verbose src/test/java/org
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy && hg add --verbose src/main/java/org
      [INFO] [src/main/java/org/Foo.java:added]
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy && hg add --verbose src/main/java/org/Foo.java
      [INFO] [src/main/java/org/Foo.java:added]
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy && hg status
      [INFO] [readme.txt:modified]
      [INFO] [project.xml:added]
      [INFO] [src/main/java/org/Foo.java:added]
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy && hg commit --message 'No msg'
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/working-copy && hg push /Users/rholt/Developer/maven-scm-provider-hg/target/test-branch
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/updating-copy && hg pull -r tip
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/updating-copy && hg id
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/updating-copy && hg diff -r -1
      [INFO] EXECUTING: /bin/sh -c cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/updating-copy && hg log --verbose

      $cd /Users/rholt/Developer/maven-scm-provider-hg/target/scm-test/updating-copy
      $find . -name Foo.java
      $ hg update
      3 files updated, 0 files merged, 0 files removed, 0 files unresolved
      $ find . -name Foo.java
      ./src/main/java/org/Foo.java

      I picked this fact up when using continuum as the newly deploy build never contained the recent changes

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              rholt Rohan Holt
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: