在 TFS 源代码管理中移动多个文件 [英] Moving multiple files in TFS Source Control

查看:36
本文介绍了在 TFS 源代码管理中移动多个文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的是 Team Foundation Server 2008 (SP 1),我需要将多个文件从一个文件夹移动到另一个文件夹(以保留文件历史记录).除了 Team Explorer(带 SP 1),我还安装了最新的 TFS Power Tools(2008 年 10 月)(用于 Windows Shell 集成).

现在,问题是我似乎无法通过 shell 或源代码管理资源管理器窗口选择和移动多个文件.我可以移动单个文件(通过右键单击 +移动"),也可以移动整个文件夹(相同的操作),但是当我选择多个文件(在一个文件夹中)时,移动"上下文项变灰/禁用.

有谁知道这是否可能..如果不可能..为什么不!?

谁能提出一个不太复杂的解决方法?

请在这里投票: https://connect.microsoft.com/VisualStudio/feedback/details/715041/support-moving-multiple-files-in-tfs-source-control-explorer 这里 http://visualstudio.uservoice.com/forums/121579-visual-studio/suggestions/2271540-allow-to-move-more-than-one-file-at-once-in-tfs-so

解决方案

使用 Visual Studio 命令行中的 tf.exe 工具 - 它可以处理通配符:

tf.exe move 

<新品>

示例:

tf.exe move "$/My Project/V*" "$/My Project/Archive"

如评论中所述:move 是重命名的别名.两个命令都移动历史记录.

I'm using Team Foundation Server 2008 (SP 1) and I need to move multiple files from one folder to another (to retain file history). In addition to Team Explorer (with SP 1) I've also got the latest TFS Power Tools (October 2008) installed (for Windows Shell integration).

Now, the problem is that I can't seem to select and move multiple files via either the shell or the Source Control Explorer window. I can move individual files (by right clicking + "Move") and I can move whole folders (same operation) but when I select multiple files (in a folder) the "Move" context item is grayed/disabled.

Does anyone know if this is possible.. and if not.. why not!?

Can anyone suggest a workaround which isn't overly complicated?

Please vote up here: https://connect.microsoft.com/VisualStudio/feedback/details/715041/support-moving-multiple-files-in-tfs-source-control-explorer and here http://visualstudio.uservoice.com/forums/121579-visual-studio/suggestions/2271540-allow-to-move-more-than-one-file-at-once-in-tfs-so

解决方案

Use the tf.exe tool from the Visual studio commandline - it can handle wildcards:

tf.exe move <olditem> <newitem>

Example:

tf.exe move "$/My Project/V*" "$/My Project/Archive"

[EDIT] As noted in the comments: move is an alias for rename. Both commands move history.

这篇关于在 TFS 源代码管理中移动多个文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆