tfs sdk - Get the Installed TFS Server version from TFS API (Is it 2010 or 2012?) -
i have wcf service calls both tfs 2010 , 2012 instances. i'm looking way distinguish between 2010 , 2012 in api, there doesn't seem getserverversion() or similar api.
the reason there slight changes in way 2010 , 2012 handle work item links:
work item links in 2010: http://tfsuri/web/wi.aspx?id=workitemid
work item links in 2012: http://tfsuri/tfsproject/_workitems/edit/workitemid
worst case can create people select version, i'd prefer automatically distinguish 2010 vs. 2012 if possible.
you can utilize ibuildserver
interface build.client version of server.
teamfoundationserver tfs = new teamfoundationserver(@"http://yourtfs:8080/tfs"); ibuildserver tfsb = tfs.getservice<ibuildserver>(); console.writeline(tfsb.buildserverversion); //v3 2010 , v4 2012
tfs tfs-sdk
No comments:
Post a Comment