TFS 2010 +当解决方案具有多个 Web 应用程序时使用 MSDeploy
我有两个解决方案
- SolutionA.sln
- WebApplication1.csproj
- SolutionB.sln
- WebApplication1.csproj
- WebApplication2.csproj
我还有两个 TFS 2010 构建配置
- BuildConfigA
- 应该构建 SolutionA 并部署 WebApplication1
- BuildConfigB
- 应该构建 SolutionB 并部署 WebApplication2(但不是 Web应用程序1)
为了防止 BuildConfigB 尝试部署 WebApplication1,我在 WebApplication1.csproj 中放置了
。但这也阻止了 BuildConfigA 部署它。我该如何适应这种情况?
I have two solutions
- SolutionA.sln
- WebApplication1.csproj
- SolutionB.sln
- WebApplication1.csproj
- WebApplication2.csproj
I also have two TFS 2010 build configurations
- BuildConfigA
- should build SolutionA and deploy WebApplication1
- BuildConfigB
- should build SolutionB and deploy WebApplication2 (but not
WebApplication1)
- should build SolutionB and deploy WebApplication2 (but not
To prevent BuildConfigB from trying to deploy WebApplication1, I put a <DeployOnBuild>false</DeployOnBuild>
in WebApplication1.csproj. But that also prevents BuildConfigA from deploying it. How could I accomodate this scenario?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这就是我最终决定要做的事情。我现在有三个解决方案
我在 SolutionB 中进行大部分开发,因为我喜欢能够轻松地引用和编译这两个项目。 的一部分之外,我根本不使用 SoluctionC
当然是 WebApplication1)
This is what I ended up deciding to do. I now have three solutions
I do most of my development in SolutionB because I like being able to easily reference and compile against both projects. I don't use SoluctionC at all other than as part of the following two build configurations
WebApplication1 of course)
嗯,我很确定构建配置也可以构建+部署单个项目,而不一定是解决方案。因此,您还可以删除 sln A 和 sln C,并将您的构建直接指向 csproj 文件。
奥哈德
Hmm I'm pretty sure a build configuration can also build+deploy single projects, not necessarily solutions. So you could also drop sln A and sln C, and point your builds directly to the csproj files.
Ohad