One of my Team Foundation Server 2010 test servers had TFS 2010, VS 2010, and Team Explorer 2010. Installed the TFS 2010 Power tools to utilize some of the cmdlets and the tfpt.exe utility to create a team project. After I did this I also needed to test the TFS Administration Tool 2.0 for TFS 2010. This is a great and free tool for managing the permissions of TFS users across TFS, SSRS, and SharePoint. This works with TFS 2010 but it is written against the TFS 2008 object model. This required
- Team Explorer 2008
- Visual Studio 2008 SP1
- Visual Studio 2008 SP1 Forward Compatibility Hotfix
I installed these pre-requisites and the TFS Admin Tool. Today I got a request to add some additional email alerts to a TFS 2008 team project. Since I already had Team Explorer 2008, I installed the TFS 2008 Power tools to get the alerts feature (The TFS 2010 Power tools doesn’t have this feature)..
I went back to work on my script for automated team project creation.
I ran my script
tfpt createteamproject /collection:http://dlvrn2010md:8080/tfs/defaultcollection /teamproject:"testauto5" /processtemplate:"MSF for Agile Software Development v5.0" /sourcecontrol:New
Then I get the following error:
TFPT.exe : Unrecognized command option 'collection'.
I realized the TFPT command is now pointing to the TFS 2008 Power tool version and obviously doesn’t know what a Team Project Collection is. I looked in the Environment Variables. The Path variable showed a reference to the TFSPowerToolsDir variable.
Next, I checked the TFSPowerToolDir variable and it was pointing to the 2008 Power Tools.
I changed this to "C:\Program Files (x86)\Microsoft Team Foundation Server 2010 Power Tools\". I reopened the PowerShell ISE, executed the script, and it worked again.
This is a unique situation, but it happened to me so it could happen to you :)
This is also posted at http://www.deliveron.com/blog/post/Fix-TFS-2010-Power-Tools-after-installing-TFS-2008-Power-Tools.aspx