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 223275 - Deleted file when change name file/folder on folder synchronized.
Summary: Deleted file when change name file/folder on folder synchronized.
Status: REOPENED
Alias: None
Product: php
Classification: Unclassified
Component: Code (show other bugs)
Version: 7.2.1
Hardware: PC Windows 7
: P4 normal (vote)
Assignee: Tomas Mysik
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-12-04 21:41 UTC by omolina90
Modified: 2012-12-06 11:34 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
IDE log (30.22 KB, text/plain)
2012-12-04 21:41 UTC, omolina90
Details

Note You need to log in before you can comment on or make changes to this bug.
Description omolina90 2012-12-04 21:41:46 UTC
Product Version = NetBeans IDE 7.2.1 (Build 201210100934)
Operating System = Windows 7 version 6.1 running on amd64
Java; VM; Vendor = 1.7.0_07
Runtime = Java HotSpot(TM) 64-Bit Server VM 23.3-b01

Have a project created in a folder Test1, then sync the folder Test2. If you change the name of a file or folder netbeans delete the file in the folder Test2 synchronized.
Comment 1 omolina90 2012-12-04 21:41:52 UTC
Created attachment 128859 [details]
IDE log
Comment 2 Petr Cyhelsky 2012-12-05 15:25:51 UTC
Please send some more information, especially steps to reproduce (what kind of sync operation??) Btw. why is this in IDE/Performance?
Comment 3 omolina90 2012-12-05 15:54:27 UTC
I did not know where to put the error component sorry. I will explain step by step:

1.- Create project in "C://test1"
2.- In "Properties/Source" in the project check "Copy files from Sources Folder to another location".
3.- Put path "D://test2" in "Copy to Folder".
4.- Edit file in project with NetBeans and save. NetBeans synchronize correct in another location: "D://test2".
5.- Change name file or folder in the project, used "Refractor/Rename" and NetBeans NOT synchronize correct in another location.

Thanks.
Comment 4 Tomas Hurka 2012-12-06 08:12:29 UTC
(In reply to comment #3)
> I did not know where to put the error component sorry. I will explain step by
> step:
> 
> 1.- Create project in "C://test1"
What kind of project should be created in C:\\test1?
Comment 5 omolina90 2012-12-06 08:15:59 UTC
PHP project.
Comment 6 Tomas Hurka 2012-12-06 08:32:16 UTC
(In reply to comment #5)
> PHP project.
I see. Assigning to PHP.
Comment 7 Tomas Mysik 2012-12-06 10:45:41 UTC
I cannot reproduce your issue, it works for me as expected. What I did exactly:

- create PHP project
- copy its sources somewhere (locally)

(a) rename php file using Refactor > Rename: "Refactoring cannot be applied in this context."
(b) rename the file directly in the Projects view: no problem
(c) rename a folder in the Projects view: no problem

If I did anything incorrectly, please let me know. If I need to rename any specific file, please let me know. Also, please try to use the development version of NetBeans [1] if possible.

Thanks for reporting.
[1] http://bits.netbeans.org/download/trunk/nightly/latest/

Product Version: NetBeans IDE Dev (Build 20121204-b5f695999ec3)
Java: 1.6.0_37; Java HotSpot(TM) 64-Bit Server VM 20.12-b01
Runtime: Java(TM) SE Runtime Environment 1.6.0_37-b06
System: Linux version 3.5.0-19-generic running on amd64; UTF-8; cs_CZ (nb)
Comment 8 Vladimir Riha 2012-12-06 10:59:08 UTC
Tomasi, I reproduced it partially doing following:
- create PHP project, set copy location somewhere (I have only 1 disk in system, so all is C:\...)
- create a folder in project in IDE
- folder is copied correctly
- select folder in IDE and choose Refactor|Rename
- rename folder and confirm
=> original folder is "removed" from the copy directory and not renamed. This happens only if the folder is empty. Once I have some files in it, it works fine.

I can't reproduce it with files.

Product Version: NetBeans IDE Dev (Build web-main-9444-on-20121206)
Java: 1.7.0_10; Java HotSpot(TM) 64-Bit Server VM 23.6-b04
Runtime: Java(TM) SE Runtime Environment 1.7.0_10-b18
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
Comment 9 Tomas Mysik 2012-12-06 11:14:11 UTC
So, it does not work only if the folder is empty, right?
Comment 10 Vladimir Riha 2012-12-06 11:17:32 UTC
Yes, at least for me
Comment 11 Tomas Mysik 2012-12-06 11:34:30 UTC
(In reply to comment #10)
> Yes, at least for me

In such case, I think it is P4.