VSTS Build 不生成最新的二进制文件 [英] VSTS Build not generating latest bin binaries

查看:17
本文介绍了VSTS Build 不生成最新的二进制文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在为 MVC 项目使用 TFS 2018 CI 管道,我也将项目的 bin 文件添加到 TFS 中,管道没有问题,它成功并成功生成工件,但主要问题是如果我做了与项目的 DLL 相关的代码中的任何更改,

I am using TFS 2018 CI pipeline for MVC project, also I added the project's bin files into the TFS, there is no problem with the pipeline, its getting succeeded and artifact is generated successfully but the main problem is that if I made any changes in code related to project's DLL,

CI 管道的构建解决方案没有生成自己的最新 bin 文件

直到或除非我手动检出 project.dll 文件,然后在文件中检入,而不是管道将选择更改,我所缺少的,使用MSBUILD"任务的结果相同,我还勾选了清理所有目录"' 但结果相同

Until or unless I manually check Out the project.dll file and than check In the file than pipeline will pick the changes, what I am missing, same result by using 'MSBUILD' tasks, I also TICK clean the 'all directories' but same result

推荐答案

我花了一整天的时间才找到解决方案,不应将 bin 文件夹添加/包含到源代码管理 (TFS/Azure) 中,

After spending whole day I came to the solution that, bin folder should not be added/included into the Source Control (TFS/Azure),

 bin folder or project's binaries should not be added in to TFS

项目中应该排除bin文件夹,做完这个操作后,当我运行相同的构建管道并检查工件时发现TFS构建相应地添加了bin文件夹和文件,这让我感到震惊.

bin folder should be excluded in the project, after doing this operation, when I run the same build pipeline and inspect the artifact found that TFS builds added the bin folder and files accordingly, thats shocked me.

在这种情况下应该记住一件事,外部 dll 引用如何,在 src 文件夹的同一级别创建一个 CommonDLLs 文件夹,并将所有外部 DLL 放在那里.它们通过相对路径引用

One thing should be remember in this case that what about external dlls reference, create a CommonDLLs folder at the same level of the src folder and put all external DLLs there. They are referenced through a relative path

这篇关于VSTS Build 不生成最新的二进制文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆