Visual Studio Online TFS拒绝“源代码控制".以$开头的文件名 [英] Visual Studio Online TFS refuses to "source control" filenames starting with $

查看:128
本文介绍了Visual Studio Online TFS拒绝“源代码控制".以$开头的文件名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

背景知识: 我已经将Win2003server上的3个旧项目迁移到Win2008R2服务器上(告别了IIS 6,VS2008和Visual SourceSafe!).具有3个项目的Visual Studio 2012解决方案可以编译并运行正常,但是我需要进行一些小的更改.在做更多事情之前,我试图将这些项目添加到源代码控制"(带有本地工作区的TFS 14.0)中.顺利添加了两个项目.第三个项目不允许将某些项目添加到团队项目文件夹中,并显示以下消息:

A bit of Background: I've migrated 3 old projects on a Win2003server to a Win2008R2 server (saying goodbye to IIS 6, VS2008, and Visual SourceSafe!). This Visual Studio 2012 solution with the 3 projects compiles and runs OK but I need to make some minor changes. Before I do much more, I am trying to add these projects to "source control" (TFS 14.0 with a local workspace). Two projects were added without problems. The 3rd project won't allow some items to be added to the team project folder and gives this message:

TF10122:路径"$/MDW/MortgageDataWeb/MDS/$ Common/$ BuildNaviagator.asp"在路径组件的开头包含一个"$".删除"$",然后重试."

这个古老的经典ASP项目的本地路径为D:\ Projects \ MortgageDataWeb \ MDS,其中一个子文件夹名为 $ Common ,其中有数十个文件以开头$ (文件名),文件类型为 .asp .

The local path of this old classic ASP project is D:\Projects\MortgageDataWeb\MDS and one of the subfolders is named $Common and within that are dozens of files beginning with a $ in the filename and the filetype is .asp.

我已经对该错误消息进行了大量研究,并推断出该项目中的文件名和文件夹名称不能以任何美元符号开头(也不包含??).大多数解释都指向我不太了解的有关构建定义"和Workflow 4.0问题的内容.

I've done lots of research on this error message and I am deducing that the filenames and folder names in this project cannot begin with (nor contain??) any dollar signs. Most every explanation points at something about "Build Definitions" and Workflow 4.0 issues which I don't really understand.

该代码是大约9年前编写的,我非常不愿意尝试进行全局源代码更改以从项目名称中删除违规的$.

The code was written about 9 years ago and I would be very reluctant to attempt global source code changes to hack out the offending $ from the item names.

是否可以做一些简单的事情来将该项目添加到TFS中,以便我可以进行较小的更改并可以使用TF版本控制来跟踪内容?我还没有准备好使用完整的ALCM功能(只是想查看未决的更改,签入,比较差异等).

Is there anything simple I could do to get this project added to TFS so I can move forward with my minor changes and be able to track things with TF version control? I'm not ready to need full-blown ALCM features (just want to view pending changes, check in, compare differences, etc.).

关于TFS的版本,我遵循了这里的建议:

Regarding versions of TFS, I followed advice from here:

https://msdn.microsoft.com/en-us/library/ms181475.aspx

其中包括一个有关如何查找版本的问题:

Included there is a question about how to find version:

A:从Web浏览器和本地TFS,输入以下地址:http://ServerName:8080/tfs/_home/About. 对于Visual Studio Online,输入以下地址:http://AccountName.visualstudio.com/_home/About.

A: From a web browser and for an on-premises TFS, enter the following address: http://ServerName:8080/tfs/_home/About. For Visual Studio Online, enter the following address: http://AccountName.visualstudio.com/_home/About.

因此,我在开发服务器上执行了此操作,得到的结果对我来说似乎是14:

So, I did this on my development server and got this which looks like 14 to me:

推荐答案

异常中的消息是正确的.根据命名语法,约定和限制 :

The message in the exception is correct. Per Naming Syntax, Conventions, and Limitations:

Team Foundation版本控制中的大多数名称不能以空格或制表符开头或结尾.可以使用任何字符作为名称或标签,除了

Most names in Team Foundation version control cannot begin or end with spaces or tabs. Any character can be used for names or labels, except

...

美元符号($)不能是文件名中的第一个字符.

A dollar sign ($) cannot be the first character in a file name.

没有解决方法.您不能将具有这些名称的文件放在TFVC中.

There is not a workaround. You cannot place files with those names in TFVC.

这篇关于Visual Studio Online TFS拒绝“源代码控制".以$开头的文件名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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