针对始终“更改”的文件的 SVN 最佳实践没有变化
我们有一个引用公共目录中文件的项目。每当打开或编译该项目时,都会复制这些文件。由于时间戳发生变化,Subversion 会将其视为更改。我只想提交通用公共目录的新更改或项目中的实际更改。不是编译器为我执行的自动复制。
如何将目录和文件保留在 SVN 中,但防止这些未更改的内容被视为更改?是否有一些“最佳实践”或“首选”方法来处理这种情况?
We have a project that references files in a Common-directory. Whenever that project is opened or compiled, these files are copied. Because the timestamp changes, Subversion sees that as changes. I only want to commit new changes of the general Common-directory, or actual changes in the project. Not the auto-copies that the compiler performs for me.
How do I keep the directory and the files in SVN, but prevent these non-changes to be seen as changes? Is there some "best practice" or "preferred" way of dealing with such situations?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
通常,您不想将编译器生成的任何内容放入存储库中。使用 svn:ignore 忽略这些内容。
Typically, you don't want to put compiler-generated anything into your repository. Use svn:ignore to ignore these things.
我认为在公共目录上使用一个简单的 svn:ignore 就可以了。没有真正改变的文件应该签入到一个单独的项目中。您必须告诉您的开发人员,他们必须签出这两个项目,但只签入包含真正更改的文件的项目。
I would think a simple svn:ignore on the common directory would do. The files that don't really change should be checked in to a separate project. You would have to tell your developers that they will have to checkout the two project but only check in the project with the files that really change.