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 212502 - Git plugin locks files, and does not release them
Summary: Git plugin locks files, and does not release them
Status: RESOLVED DUPLICATE of bug 218443
Alias: None
Product: versioncontrol
Classification: Unclassified
Component: Git (show other bugs)
Version: 7.3
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: Ondrej Vrabec
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-14 22:13 UTC by Petah
Modified: 2012-11-02 13:18 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Petah 2012-05-14 22:13:52 UTC
After I start Netbeans, some files in the .git directory gets locked.

If I try to delete these files it fails...

rm: cannot unlink `src\\dependencies\\some-module/.git/objects/pack/pack-09e580a4d7c62a821e101e78e2ccdaf416cc7d71.pack': Permission denied
rm: cannot remove directory `src\\dependencies\\some-module/.git/objects/pack': Directory not empty
rm: cannot remove directory `src\\dependencies\\some-module/.git/objects': Directory not empty
rm: cannot remove directory `src\\dependencies\\some-module/.git': Directory not empty

In my particular situation there is multiple nested git repositories

project\.git
project\src\dependencies\some-module\.git
project\src\dependencies\some-module-other\.git
project\src\dependencies\some-module-other\sub-module\.git

etc
Comment 1 Ondrej Vrabec 2012-05-15 07:01:45 UTC
And if netbeans is not started are you able to delete them? In that case NetBeans is probably running some scanning and reads from the file. BTW, isn't "Permission denied" something different then that the file is opened in another process?
Anyway, deleting metadata folders while the IDE is working with them is not a good idea and i don't intend to support that in any case.
Comment 2 Petah 2012-05-15 21:58:29 UTC
Yes, If I close Netbeans, I can delete them.


Also Netbeans does not indicate that it is scanning, and even after leaving it for more than 30mins (for a small repo) it is still locked.

And no, you get permission denied in the console when using rm, but if I try to delete it in Windows Explore it says cannot delete file because it is in use by another process.

My particular case I copied a sub directory in my project to another directory, and then tried to delete the old one.
Comment 3 lightglitch 2012-11-02 13:14:50 UTC
I reopening this because in the development release you added support for composer in php but because netbeans locks the files when we run a "composer update" command he is unable to delete the folders if necessary.
Comment 4 Ondrej Vrabec 2012-11-02 13:18:40 UTC

*** This bug has been marked as a duplicate of bug 218443 ***