1
I have a folder that contains files I have compiled in .NET (however this question could easily apply to a non-programmer's folder too, e.g. containing word documents or whatever.)
When I try to clear it out using the Command Prompt:
del /F /S *
Then I get an "Access is Denied" on a certain file. This is definitely not due to security so it must be a lock.
However when I use Cygwin I am able to delete it:
$ rm -r *
So what is Cygwin doing that is special. Can I emulate this some how from the regular command prompt?
By the way this happens enough times 100+ so that it isn't a fluke that the file got unlocked before I opened Cygwin. Definitely Cygwin is able to unlock it somehow but regular Command Prompt cannot do it.
It could be due to security. Are you running the Windows command prompt as administrator? That might be significant, depending on the files you are trying to delete. – toryan – 2014-01-08T00:28:57.140
Yes running Windows command prompt as admin. Would be interesting to know what cygwin does differently under the bonnet. Maybe it goes in at a lower level to delete the file. – Martin Capodici – 2014-01-28T02:53:02.850