为什么TeamCity缺少参考并且编译失败? [英] Why does TeamCity miss a reference and fails compilation?
问题描述
我对TeamCity完全陌生,我使用一个简单的Visual Studio 2008解决方案来学习它。
I'm completely new to TeamCity and I'm using a simple Visual Studio 2008 solution to learn it.
我的解决方案有2个项目:ConsoleApplication1和ClassLibrary1。
My solution has 2 projects: ConsoleApplication1 and ClassLibrary1.
ConsoleApplication1引用了ClassLibrary1。解决方案在VS直接编译没有问题。
ConsoleApplication1 has a reference to ClassLibrary1. The solution compiles with no problem in VS directly.
但是,当我尝试编译相同的解决方案在TeamCity,它失败,错误:
However, when I try to compile the same solution in TeamCity, it fails with error:
Program.cs(13,25):错误CS0246:找不到
类型或命名空间名称'ClassLibrary1'
缺少一个
使用指令或程序集
引用?)
Program.cs(13, 25): error CS0246: The type or namespace name 'ClassLibrary1' could not be found (are you missing a using directive or an assembly reference?)
据我所知,.sln文件包含检索依赖项目所需的信息。
As far as I understand, the .sln file contains the required information to retrieve the dependency project.
我可以如何帮助TeamCity cmpile解决方案?
What can I do help TeamCity cmpile the solution?
推荐答案
问题是.sln文件在存储库上重复,在两个不同的位置,我配置了TeamCity构建错误的...
The problem was that the .sln file was repeated on the repository, on two different locations, and I configured the TeamCity to build the wrong one...
这篇关于为什么TeamCity缺少参考并且编译失败?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!