本文共 1485 字,大约阅读时间需要 4 分钟。
One of the new features for 2010 Version Control is the ability to rollback or undo a changeset or check-in inside the product and see it as a new pending change type (and new change type in the history) inside Team Explorer. This feature has been available in TFS 2008 but you had to use the . The only gotcha for the TFS 2010 implementation is that you have to use the command-line application tf.exe to actually perform the rollback operation. More information about the tool is available here in the MSDN Library:
The syntax is:
tf rollback /changeset:changesetfrom~changesetto [itemspec] [/recursive] [/lock:none|checkin|checkout] [/version:versionspec] [/keepmergehistory] [/noprompt] [/login:username,[password]]
tf rollback /toversion:versionspec itemspec [/recursive] [/lock:none|checkin|checkout] [/version:versionspec] [/keepmergehistory] [/noprompt] [/login:username,[password]]
Versionspec: Date/Time D"any .Net Framework-supported format" or any of the date formats of the local machine Changeset number Cnnnnnn Label Llabelname Latest version T Workspace Wworkspacename;workspaceowner
If you have the August 2011 or later version of the installed, you now have the ability to fire off a rollback straight from Team Explorer without having to use the command-line approach. The main way would be to fire it off from the Source Control Explorer window.
However, you can start the rollback process from the Changeset History window as well.
转载地址:http://lljab.baihongyu.com/