Reputation: 2680
We are using Visual Studio 2010 Ultimate and TFS 2010 Enterprise on Windows Server 2008, R2. For an upcoming code freeze, I need to quickly check whether any developers have files checked out. Is there a way to do this which is built into TFS and/or Visual Studio 2010?
Upvotes: 31
Views: 56326
Reputation: 51
Upvotes: 5
Reputation: 5381
I know this is old, but none of the answers gave specific examples of how to make this work. So here is what I came up with (TFS Server 2008).
First, open the Visual Studio Developer command prompt.
Execute the following command:
tf status $/MyFolder /user:* /recursive
The form being:
tf status itemspec /user:username /recursive
The key is the /user:* parameter, which forces TFS to look at the server and determine all the checked out files in the path specified in the itemspec parameter. If you don't use the wildcard you will only see files you personally have checked out.
For the specific use case, you would want to put this in a file versus to screen so it would look like this:
tf status $/MyFolder /user:* /recursive > c:\MyPendingCheckouts.txt
Note I ran this with VS2012 command prompt.
Upvotes: 9
Reputation: 57892
For a built-in method, you can use the tf command line tool's status command.
Just open a Visual Studio command prompt from your start menu to use it. By default it lists the status of your own workspace but if you can figure out the command line you can list other people's workspaces too.
Edit:
tf status /user:* /recursive
should do what you want.
If you run it in a locally-mapped folder you won't need to specify which files to search, or you can just include a filespec like tf status $/MyProject/SomeFolder/*.* /user:* /recursive
Upvotes: 27
Reputation: 14052
As an alternative to using the tf status
command you can also install the TFS 2010 power tools.
You can then right click on any folder in Source Control Explorer and select "Find in source control" > "Status"
the default option is to find all checked out files in the path you have slected.
Upvotes: 45
Reputation: 55571
I find TFS Side Kicks useful for this. You can use the status side kick to look for checkouts.
Upvotes: 1