Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-3879

branch is not updated to

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • mercurial-plugin
    • None
    • Platform: PC, OS: Windows XP

      The mercurial plugin provides a branch field. I would expect that if this is
      used, the slave's copy of the repository would be updated to the specified
      branch. It is not, instead it is left at the default branch.

      I created a simple repository with a named branch. The console output is
      Started by user anonymous
      [workspace] $ hg update -C .
      0 files updated, 0 files merged, 0 files removed, 0 files unresolved
      [workspace] $ hg --config extensions.purge= clean --all
      [workspace] $ hg incoming --quiet --bundle hg.bundle --template "<changeset
      node='

      {node}

      ' author='

      {author|xmlescape}

      ' rev='

      {rev}

      '
      date='

      {date}

      '><msg>

      {desc|xmlescape}

      </msg><added>

      {file_adds|stringify|xmlescape}

      </added><deleted>

      {file_dels|stringify|xmlescape}

      </deleted><files>

      {files|stringify|xmlescape}

      </files><parents>

      {parents}

      </parents></changeset>\n"
      -r branch1
      [workspace] $ hg pull -u hg.bundle
      pulling from hg.bundle
      searching for changes
      adding changesets
      adding manifests
      adding file changes
      added 1 changesets with 1 changes to 1 files
      0 files updated, 0 files merged, 0 files removed, 0 files unresolved
      Finished: SUCCESS

      The workspace repository isn't updated to the requested branch
      C:\Users\ben\.hudson\jobs\HudsonMercurialTest\workspace>hg branch
      default

      C:\Users\ben\.hudson\jobs\HudsonMercurialTest\workspace>hg identify
      1333768e2c9e

      C:\Users\ben\.hudson\jobs\HudsonMercurialTest\workspace>hg log
      changeset: 2:a723eea10923
      branch: branch1
      tag: tip
      user: Ben Mathews <Ben.Mathews@HexagonMetrology.com>
      date: Tue Jun 16 10:34:57 2009 -0600
      summary: branch 1 commit

      changeset: 1:1333768e2c9e
      user: Ben Mathews <Ben.Mathews@HexagonMetrology.com>
      date: Tue Jun 16 10:32:51 2009 -0600
      summary: 'test'

      changeset: 0:c9ec671340fe
      user: Ben Mathews <Ben.Mathews@HexagonMetrology.com>
      date: Tue Jun 16 10:31:53 2009 -0600
      summary: 'test'

      Either as part of the hg pull command or as a seperate command, the repository
      needs to be updated to branch1.

      Thanks

            jglick Jesse Glick
            benmathews benmathews
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: