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

Team Foundation Server Plugin: Team System Web Access repository browser links broken for TFS 2012 and 2013

XMLWordPrintable

      When using TFS and you change the "Repository Browser" field in the Source Code Management section of a job config to "Team System Web Access", it generates links to the repository browser on the Changes screen of each job run.

      The problem is that the link builder for the TFS plugin is for some specific (undocumented?) version of TFS. The plugin should either support more versions of TFS (and be capable of inferring them) or maybe add version-specific browser options.

      For example, the plugin doesn't specifically support TFS 2012+, so if you select Team System Web Access and provide the TFS server url of "https://tfs.com/tfs", it drops the path anyway and generates the following links for each changeset:
      https://tfs.com/cs.aspx?cs=

      {changeset number}
      and for each file link:
      https://tfs.com/view.aspx?path={TFS file Path}&cs={changeset number}

      and for each diff link:
      https://tfs.com/diff.aspx?opath=

      {TFS file Path}&ocs={previous change set #}&mpath={TFS file Path}

      &mcs=

      {current change set #}

      However, TFS 2012 and 2013 require changeset URLs in the following format:
      https://tfs.com/tfs/

      {CollectionName}

      /

      {ProjectName}

      /_versionControl/changeset/

      {change set #}

      CollectionName and ProjectName can probably be extracted from the TFS path from the job, but maybe you should allow the user to provide the entire project path and just add everything after that (/_versionControl/changeset/nnn). ProjectName can literally be any valid project in the collection, but CollectionName needs to be an exact match.

      File content and compare views use an URL hash:

      {changesetUrL}

      #path=

      {TFS file path}&_a=contents {changesetUrl}#path={TFS file path}

      &_a=compare

      Maybe the plugin links are only supposed to work for codeplex or very old versions of TFS?

            jessejacob Jesse Jacob
            jessejacob Jesse Jacob
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: