TFS 2015 CI - Build artifacts are not generating for Console application in the solution which has web, console and WCF projects

坚强是说给别人听的谎言 提交于 2019-12-11 07:04:13

问题


I am creating a continuous integration using TFS 2015 CI for a project solution which has combination of Web project, WCF Project , class libraries and Console Applcation. The Project is structured as shown below

Project Solution
 Project 1 (Web UI Project)
 Project 2 (WCF Project)
 Project 3 (Console Application-Batch Scheduler)
 Project 4 ( Class library)
 Project 5 ( Class library)
 Project 6 ( Class library)

I have added the MSBuild task and included the following arguments ,

/p:DeployOnBuild=true /p:Configuration=Release /p:OutDir=$(Build.ArtifactStagingDirectory) 

The Problem is , All the dlls and build files generated in the Build artifacts directory for Web , WCF and class libraries project but not for the console application project.

Am I missing anything in MS Build argument or Is there any project specific setup required to generate the exe and release files for the console application in build artifact directory.

NOTE: In the TFS CI, Build is partially succeeded due to some long name issues in the web project but builds successfully in the local solution.

Thanks,


回答1:


First go through your build artifacts directory with all folder and sub-folders.You may have not noticed it. There is not any project specific setup required to generate the exe and release files for the console application in build artifact directory.

Build.ArtifactStagingDirectory

The local path on the agent where any artifacts are copied to before being pushed to their destination. For example: c:\agent_work\1\a.

A typical way to use this folder is to publish your build artifacts with the Copy files and Publish build artifacts steps.

Just need to make sure you have published the artifacts to the server or a share folder. To narrow down this issue, you could also try to directly build the Console Application project to see if the .exe generated successfully. And create a new normal Console Application instead of Console Application-Batch Scheduler to narrow down if the issue is related to it.



来源:https://stackoverflow.com/questions/44732208/tfs-2015-ci-build-artifacts-are-not-generating-for-console-application-in-the

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!