svn:ignore exclude a file from being ignored

故事扮演 提交于 2019-12-11 02:12:33

问题


I have a directory which contains files with various extensions. I would like to do the equivalent of the following .gitignore code in svn:ignore:

*.* # ignore everything
!.htaccess # except this file

How do I achieve this in svn:ignore?


回答1:


If you've already added the .htaccess file to SVN control, then it won't matter. You will always see changes to that file. The only time the ignore list comes into play is for files which have not yet been added to the repository. You can ignore everything in the directory globally and still add the .htaccess file to SVN control and see modifications, etc.




回答2:


I don't think you can - svn:ignore takes in a blacklist (files to be ignored), not a whitelist (files that are not to be ignored).



来源:https://stackoverflow.com/questions/18056183/svnignore-exclude-a-file-from-being-ignored

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