I inadvertently added some dynamically build directories and files to CVS in my Eclipse project. Now after deleting these files, committing changes and running the build files are shown as new (question mark) but directories are shown as committed. Now I know the开发者_StackOverflow中文版 hard way to deal with this situation that requires me to manually delete unneeded directories from the repo but all I'm really trying to do is to add the top unneeded dir to .cvsignore
so any files there will be ignored on commit. However Team->Add to .cvsignore
menu option is at this point grayed out and if I add .cvsignore
manually it is (for lack of a better word) ignored.
Can this be done without cleaning directories out from the history? And if yes - how?
Since no one came forward with the answer I'm going to answer this. Or rather I will tell you how I ended up dealing with this problem. So I think it doesn't have other solution just because CVS directories are "permanent". I had to open CVSROOT/history file and manually delete all lines corresponding to the directories that I no longer want. After that I also deleted all .CVS folders inside the directories I wanted to get rid of. Refresh and add to .cvsignore. Enjoy!
Even though the problem is solved I would like to add what just worked out for me. I just deleted the local files and then commited to cvs, after this, the option "add to .cvsignore" became available. So, in my case there was no need to access the cvs server, cvs just seem to avoid adding files already is in his control to be ignored.
So, delete, commit, create the new file (locally, same name, but don´t commit) and then right button (eclipse) -> Team -> add to .cvsignore, it should work great. .
I know this is an old question but since Douglas's trick didn't work for me (I couldn't commit the deletion of the directory), I and a colleague had to find another workaround.
These steps solved our problem:
In your OS's file manager, go to the directory that includes the troublesome directory
Find the folder
CVS
, and in it, open theEntries
fileFind the row that includes the name of the directory, in the form
D/directoryname////
Delete that row, save, and refresh the directory in Eclipse.
If the folder is defined in .cvsignore
, it should now stay away from the synchronize view.
精彩评论