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

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

问题描述

我们的主要项目使用 Team Foundation Server.每次我们在现场或异地添加新员工时,我们总是必须手动设置参考.

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.

TFS 是否可以将 dll's 复制/保存/传递给新用户而无需每次都安装它们?

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

例如,我添加新功能并将 DocumentFormat.OpenXml 安装到我的项目中.设置它运行的代码并在我的机器上正常工作,我发布它可以正常工作.我将所有内容都签入 TFS.

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.

我的同事下载了该项目并尝试构建它,但它出错说它不知道如何处理 DocumentFormat.OpenXml,因为不存在引用.

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.

因此他们必须下载DocumentFormat.OpenXml,然后才能构建和运行项目.

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

TFS 有没有办法帮我们省下这一步?

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

推荐答案

与 TFS 无关,真的.您只需将依赖项签入源代码管理.

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

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

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>......DependenciesExample.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天全站免登陆