TFS dll和引用问题 [英] TFS dll and references issues

查看:1726
本文介绍了TFS dll和引用问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们使用Team Foundation Server作为我们的主要项目。每次我们现场或非现场添加新员工时,我们都必须手动设置参考。



TFS是否可以复制/保存/传递 dll的给新用户,而不必每次都安装它们。



例如我添加新功能并安装 DocumentFormat.OpenXml 到我的项目。设置它运行的代码,在我的机器上工作正常,我发布它的工作原理很好。我检查所有的东西到TFS。



我的同事下载项目尝试构建它,它错误地说,它不知道该怎么处理$ $ $ c> DocumentFormat.OpenXml 因为没有引用。



所以他们必须下载 DocumentFormat.OpenXml 然后他们可以构建和运行项目。



TFS有没有办法保存我们这一步?

解决方案

p>与TFS无关,真的。你只需要检查你的依赖来源控制。



在你的解决方案中,添加一个名为依赖关系的文件夹。在解决方案层次结构中的相同位置的磁盘上添加匹配的文件夹(烦人,我知道)。将您的从属外部DLL添加到该目录。





由于这些都是解决方案的一部分,他们将随着解决方案一起进入源代码管理。



在项目中引用这些。它将看起来像这样





但它应该作为相对路径记录在您的解决方案文件中。

 <引用包含=示例> 
< HintPath> .. \..\..\Dependencies\Example.DLL< / HintPath>
< / Reference>

如果您没有遇到问题,您可以简单地编辑项目文件,更改提示路径。


We use Team Foundation Server for our main project. Every time we add a new employee either onsite or offsite we always have to set up the references manually.

Is it possible for TFS to copy/save/pass the dll's to the new user without having to install them every time?

For example I add new functionality and install DocumentFormat.OpenXml to my project. Set up the code it runs and works fine on my machine, I publish it works just fine live. I check in everything into TFS.

My co worker downloads the project attempts to build it and it errors out saying it doesn't know what to do with DocumentFormat.OpenXml because no reference exist.

So they they must download DocumentFormat.OpenXml and then they can build and run the project.

Is there a way for TFS to save us this step?

解决方案

Nothing to do with TFS, really. You just have to check in your dependencies to source control.

In your solution, add a folder called "Dependencies". Add a matching folder on disk in the same location in your solution hierarchy (annoying, I know). Add your dependent external DLLs to that directory.

As these are now part of the solution, they will travel with the solution into source control.

Reference these in your projects. It will look like this

but it should be recorded in your solution file as a relative path.

<Reference Include="Example">
  <HintPath>..\..\..\Dependencies\Example.DLL</HintPath>
</Reference>

If you're having problems with this not being the case, you can simply edit your project file and change the hint path.

这篇关于TFS dll和引用问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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