Bug 21420 - Changing .classpath doesn't update JDT
Summary: Changing .classpath doesn't update JDT
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows 2000
: P1 major (vote)
Target Milestone: 2.1 M1   Edit
Assignee: Jerome Lanneluc CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-07-09 15:48 EDT by Randy Hudson CLA
Modified: 2002-09-18 09:02 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Randy Hudson CLA 2002-07-09 15:48:35 EDT
If you look at how SWT packages their project in CVS, they have 
multiple .classpath_PLATFORM files.  By renaming one of them to .classpath, 
overwriting the current .classpath for that project, the project should be 
rebuilt using the new .classpath.  This doesn't happen.  The workaround is to 
dirty the .classpath file and then save it.  Otherwise, the list of source 
folders is not refreshed.

My guess is that the builder is looking for changes to the .classpath file, but 
not changes to any file which is then renamed to be ".classpath".
Comment 1 Philipe Mulet CLA 2002-07-10 11:57:54 EDT
Good point. We should also consider the MOVE scenario.
Comment 2 Philipe Mulet CLA 2002-07-10 12:03:47 EDT
Actually, I take my previous comment back. The support for detecting .classpath 
change should capture this scenario. A delta should be notified for 
Added .classpath file, moved from other one.

Need to investigate.
Comment 3 Jerome Lanneluc CLA 2002-07-10 12:14:48 EDT
Was able to reproduce: you have to rename the .classpath from the Navigator 
view to see the problem.
Comment 4 Randy Hudson CLA 2002-07-10 13:14:08 EDT
In addition, I found it difficult to perform this operation in general.  For 
example, I wanted to delete the current .classpath, and then copy 
the .classpath_win32 to be the new .classpath.  (I had to do this because 
trying to copy straight to .classpath isn't allowed when the file already 
exists).  So, as I delete the existing .classpath, a new one get's places there 
automatically, even with Autobuild off.
Comment 5 Philipe Mulet CLA 2002-07-24 12:55:03 EDT
Fix won't be ready for 2.0.1. Marking for 2.1 instead.
Comment 6 Jerome Lanneluc CLA 2002-08-23 09:45:07 EDT
We used to consider only IResourceDelta.CONTENT changes to the .classpath file.
Now considering IResourceDelta.MOVED_FROM changes.

Randy, for the fact that when you delete a .classpath file it reappears 
automaticaly, please enter a separate bug. However I doubt this will change as 
this is by design and this ensures that the classpath is not lost in case of a 
crash.
Comment 7 David Audel CLA 2002-09-18 09:02:25 EDT
Verified.