This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 235197

Summary: Removing folder added to project does not remove sourceRootList entry in project.xml
Product: cnd Reporter: MackSix
Component: ProjectAssignee: Alexander Simon <alexvsimon>
Status: RESOLVED WONTFIX    
Severity: normal CC: MackSix
Priority: P4    
Version: 7.4   
Hardware: PC   
OS: Windows 7   
Issue Type: DEFECT Exception Reporter:

Description MackSix 2013-08-29 04:33:30 UTC
1. Right click on a C/C++ Project or folder and choose "Add Existing Items from Folders..." and add some folder with some files in it.
2. Close project and reopen it. Notice the added folder shows in the Project and Files windows.
3. Right click on the added folder in Projects Window and remove it.
4. The folder is removed in Project Window but still shows in Files Window.
5. The <sourceRootList> entry in project.xml is still present and is not removed, so the folder will always show in the Files Window.


Workaround: Remove the everything between the <sourceRootList> </sourceRootList> you don't want and restart NetBeans.


Product Version: NetBeans IDE Dev (Build 201308280001)
Java: 1.7.0_40; Java HotSpot(TM) 64-Bit Server VM 24.0-b55
Runtime: Java(TM) SE Runtime Environment 1.7.0_40-b40
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
Comment 1 MackSix 2013-08-29 05:05:38 UTC
If after manually deleting the project.xml <sourceRootList> entries and then adding a folder later, NetBeans automatically writes the old entries that were removed back to the list. 

Workaround: None that I know of. (Deleting cache?)
Comment 2 MackSix 2013-08-30 07:02:15 UTC
I see now, there are entries in the project.xml and configuration.xml that both need removed or removed folders come back.
Comment 3 Alexander Simon 2013-08-30 08:28:33 UTC
(In reply to MackSix from comment #1)
> If after manually deleting the project.xml <sourceRootList> entries and then
> adding a folder later, NetBeans automatically writes the old entries that
> were removed back to the list. 
> 
Workaround: 
Project properties->General:
- remove source root