我应该在版本控制存储库中添加第三个库的 dll 吗?
版本控制最佳实践。 在开发程序时,我使用第三方库、NUnit 等。 我想分享托管在 http://www.codeplex.com/ 或 http://code.google.com/hosting/。
第三库有哪些好的做法? 我应该在版本控制中添加第三个库的 dll 吗?
谢谢你,
Version control Best practices.
When developing a program, I use third party libraries, NUnit and others.
I want to share the sources of this program hosted on http://www.codeplex.com/ or http://code.google.com/hosting/.
What are good practices as regards third libraries?
Should I add the dll of my third libraries in the version control ?
Thank you,
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
随着 NuGet 的引入,您可以通过不同的方式来执行此操作。
请参阅 David Ebbo 的这篇文章:使用 NuGet 而不提交包< /a>.
基本上,您使用 NuGet 下载包引用并将其添加到所需的库(假设有您需要的库的 NuGet 包),但不要将 Packages 文件夹添加到存储库。
相反,您可以修改需要包的项目的预构建步骤,以便它们在所需的包不存在时自动下载所需的包。
测试表明,在检查库是否存在时,这会给构建过程带来轻微的延迟,因此这对您来说可能足够好,也可能不够好。
With the introduction of NuGet you have a different way to do this.
See this post by David Ebbo: Using NuGet without committing packages.
Basically you use NuGet to download and add package references to the libraries you want (assuming there's NuGet packages for the libraries you need), but do not add the Packages folder to your repository.
Instead you modify your pre-build step of the projects that require packages so that they automatically download the packages required if they're not present.
Testing has shown that this adds a minor delay to the build process when checking if the libraries are present, so this may or may not be good enough for you.
我们总是这样做,尤其是当我们链接特定版本时,我们有一个 NUnit 文件夹,然后其中有一个版本文件夹。
We always do especially if we are linking against a specific version, we have an NUnit folder for example and then a version folder within it.