Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Find all locked files in TFS

Tags:

tfs

tf-cli

I would like to see all files that are locked. so far, I've only found to use tf.exe status and look for anything with '!' because they are not reported as "lock, edit" as they are in the UI. Any ideas? thanks.

like image 223
TheSean Avatar asked Jun 25 '09 02:06

TheSean


People also ask

How do you remove a lock in TFS?

File -> Source Control -> Advanced -> Workspaces... In the dialog that came up, I checked "Show remote workspaces" and the locked workspace came up in the window. I then selected it and clicked "Remove".

How do I find a locked file in Linux?

Lock files should be stored within the /var/lock directory structure. Lock files for devices and other resources shared by multiple applications, such as the serial device lock files that were originally found in either /usr/spool/locks or /usr/spool/uucp , must now be stored in /var/lock .

How do you unlock a file in Visual Studio?

Unlock a folder or file from Source Control Explorer While working in the server workspace, navigate to the View menu and choose Other Windows, then choose Source Control Explorer. In Source Control Explorer, open the shortcut menu for the folder or file from which you want to remove a lock, and then choose Unlock.


1 Answers

If you have the power tools installed, it's a one-liner:

tfstatus . -r -user * | % { $_.pendingchanges } | ? { $_.islock } | select -unique serveritem

If you prefer GUIs to scripts, try TFS Sidekicks.

like image 129
Richard Berg Avatar answered Oct 19 '22 14:10

Richard Berg