|Important||This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here.|
Use /gc to create a project-specific group.
To use the /gc command, you must be a member of the Team Foundation Administrators security group. For more information, see Team Foundation Server Permissions.
Even if you are logged on with administrative credentials, you must open an elevated Command Prompt to perform this function on a server that is running Windows Server 2008. To open an elevated Command Prompt, click Start, right-click Command Prompt, and click Run as Administrator. For more information, see the Microsoft Web site.
Specifies the project GUID or URI of the team project. To view the URI, copy http://localhost:8080/services/v1.0/CommonStructureService.asmx to the browser, click ListAllProjects on Team Foundation Server, and then click Invoke.
Specifies the project group name.
Optional. Specifies the project group description.
Required. Specifies the name of the application-tier computer.
The following example creates a group specific to the project specified by the URI: "vstfs://Classification/TeamProject/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx." The group is named "Test Group" and it has the description "This group is for testing."
You must replace the placeholder GUID with the URI of the team project for which you want to create this group. To view the team project's URI, copy http://localhost:8080/services/v1.0/CommonStructureService.asmx to a browser on the application-tier for Team Foundation Server, and then click Invoke. The team project URI is displayed enclosed in the <Uri></Uri> tag.
After you run the command, you can verify the group in Team Explorer. Right-click the team project you used in the command, click Team Project Settings, and then click Group Memberships. Test Group is included in the Groups list in the Project Groups on <team project name> dialog box.
>TFSSecurity /gc "vstfs:///Classification/TeamProject/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" "Test Group" "This group is for testing" /server:MyServer