SVN:忽略子文件夹
我有一个文件夹:/user_files
,我想将其包含在 SVN 中,但它下面还有一些我不想包含的文件夹。
有没有办法使用 svn:ignore 忽略文件夹中的任何内容,即使该父文件夹包含在存储库中?
I have a folder say: /user_files
, which I want to include in SVN, but there are additional folders underneath it which I don't want to include.
Is there a way to use svn:ignore
to ignore anything in a folder even if that parent folder is included in the repos?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
使用此选项可以忽略 user_files 目录中的所有内容:
这会将
user_files
目录上的svn:ignore
属性设置为*
,这实际上会导致 svn忽略该目录中所有未跟踪的文件。然后,您必须提交设置属性的目录,并更新其他工作副本。
Use this to ignore everything in the user_files directory:
This sets the
svn:ignore
property to*
on theuser_files
directory, which effectively causes svn to ignore every untracked file in this directory.Then you have to commit the directory on which you set the property, and update other working copies.
.svnignore
不会阻止您添加内容 - 它只是禁止在svn stat
中报告它们。您可以将/user_files
放入.svnignore
中,然后从那里强制添加您想要添加的内容。.svnignore
doesn't stop you from adding things - it just suppresses them being reported insvn stat
. You could put/user_files
in your.svnignore
and then force-add the things you want to add from there.