Reputation: 60099
I would like to make it so that Subversion ignores my NetBeans IDE project configuration directories ("nbproject/") and their contents for all projects all the time. I read in the SVN docs that you can set global ignore patterns in ~/.subversion/config
. For example, in my config I have...
### Set global-ignores to a set of whitespace-delimited globs
### which Subversion will ignore in its 'status' output, and
### while importing or adding files and directories.
global-ignores = *.o *.lo *.la .class #*# .*.rej *.rej .*~ *~ .#*
.DS_Store *.log nbproject
Despite nbproject
being in there, SVN does not ignore it. It shows up in status reports. Any way to prevent that?
The nbproject
dir did somehow get into the repo, but I removed it. Even though it's not in the repository and does not contain a .svn
dir, SVN refuses to ignore it. Maybe because it was somehow noted in the parent dir's .svn
dir?
Update
I just completely deleted it from SVN and the filesystem and recreated the project. Now SVN is respecting the ignore pattern. I don't know why it wasn't before.
Upvotes: 6
Views: 12449
Reputation: 13078
I had the same problem. The ignore-globals was exactly as above but since nbproject was already under subversion it was showing up in status.
do:
svn rm nbproject --keep-local
that should fix it. Did for me anyways.
Upvotes: 1
Reputation: 391276
Note that ignore patterns in the config file only take effect when you add things.
If you already have the project in SVN, you need to manually attach the property afterwards.
And if you've got the directory you want to ignore in the repository, you need to get rid of it and clean up before adding the property.
Upvotes: 9
Reputation: 28147
You can also do a svn propedit svn:ignore /path/to/dir, which will open up an ignore file. From there just type the * wildcard, and svn should ignore everything.
Upvotes: 1
Reputation: 2452
I can't reproduce this with svn, version 1.6.2 (r37639): a directory that is not under version control gets ignored as it's supposed to be.
Upvotes: 1