I only want to check out a path with powershell and also check in this path one minute later at Team Foundation Server.
How can i do this?
I have installed the tfs power tools at my server.
I only want to check out a path with powershell and also check in this path one minute later at Team Foundation Server.
How can i do this?
I have installed the tfs power tools at my server.
Here is a function which will check to see if the snapin is installed. If you installed the powertools, it uses that, otherwise, it uses the command line tool
tf.exe
If you have the power tool commandlets installed for powershell. You don't need the Path like Kieth mentions, part of the commandlets aliases tf for the full tf.exe path. So, simply use the tf.exe command line reference here and all of these should work if you have the powershell commandlets installed correctly.
You should make sure your powershell has them installed by using this command though
This is my solution:
Another option is to use the wild-card if you're trying to handle multiple files in the same command without picking up other files or looping over them.
You don't need the power tools. Just use the tf.exe command line util that comes with Visual Studio with TFS Team Explorer.
tf edit <file> /noprompt
to check out andtf checkin <file> /comment:$comment /noprompt
to check in. Look at the command line usage on tf.exe for more infotf /?
andtf checkin /?
. You will need to configure your PowerShell session with the Path to tf.exe. This is usually done by the VS vars batch files. But you should be able to simply add to the path like so:$PATH += "${VS110COMNTOOLS}..\Ide"
.