locked
TFS Command Line Get Command RRS feed

  • Question

  • User-308844114 posted

    Hi

    Can you pls help me how to pull the latest version or label from the TFS through Command Line. I went through the msdn documentation. I am not able to get a clear picture.

    I am expecting some command with example where I can pass the server name, Credentials and sourcepath and Destination path.

    Basically I want to pull the get latest to a local path which  will be specified in the command line utility. Hope so I am clear. 

    Pls help me.

    Tuesday, November 11, 2008 3:27 PM

All replies

  • User1968999875 posted

     You can use tf command line utility

    This utility can be found in C:/ProgramFiles/Microsoft Visual Studio (9 or 8 )/Common7/IDE/tf.exe

    To do get latest you can use

    tf get itemspec [/version:versionspec] [/all] [/overwrite] [/force] [/preview] [/recursive] [/noprompt]

    tf get is command

    itemspec is used to get latest the specific item

    /all switch is used to get all the items

    /overwrite switch is used to overwrite all existing local files

    /force /recursive and /noprompt are some other usefule switches which can be of your interest.

    Prior to this you must have your project to be mapped with the TFS at least once.

    if you are using /noprompt then it will not ask for any confimations so it will skip you asking user name and password to login to the TFS account.So use /noprompt carefully.

    Hope this helps

    Monday, March 23, 2009 4:33 PM
  • User495843821 posted

    Hi Pal.

    DId you get a solution for this? because I´m still wondering how to do it properly.

    For me I get the same exception all the time "unable to determine workspace".

    Please if you know the answer, share!

    Wednesday, January 18, 2017 9:28 PM