我必须使用“DesktopBuild”吗?使用 TFSBuild 执行 MSBuild 脚本时的目标?
我想创建一个 msbuild 脚本,仅将应用程序从我的 CI 服务器提升到生产环境(从 A 复制到 B)。所以我不想或不需要 TFSBuild.proj 来构建解决方案。在这种情况下没有解决方案可以构建它。
我该怎么做?我可以更改项目“DefaultTargets”以指向我在 TfsBuild.proj 中定义的自定义目标吗?那么我可以改变下面的内容吗?
<Project DefaultTargets="DesktopBuild" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="3.5">
<!-- Do not edit this -->
<Import Project="$(MSBuildExtensionsPath)\Microsoft\VisualStudio\TeamBuild\Microsoft.TeamFoundation.Build.targets" />
谢谢!
I would like to create an msbuild script that just promotes an application from my CI server to production (copies from A to B). So I don't want or need the TFSBuild.proj to build a solution. There is no solution for it to build in this case.
How can I do this? Can I just change the project "DefaultTargets" to point to custom targets that I define within my TfsBuild.proj? So can I just change the below?
<Project DefaultTargets="DesktopBuild" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="3.5">
<!-- Do not edit this -->
<Import Project="$(MSBuildExtensionsPath)\Microsoft\VisualStudio\TeamBuild\Microsoft.TeamFoundation.Build.targets" />
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
幸运的是我回答了我自己的问题。您可以在“\Microsoft.TeamFoundation.Build.target”导入下覆盖桌面构建中的基本所有内容,
请参阅此 帖子如果您遇到此问题!
I answered my own question fortunately. You can override basically everything in Desktop build beneath the Import of "\Microsoft.TeamFoundation.Build.target"
See this Post if you are having this problem!