Tuesday, July 19, 2011

Delete long file path names.

I made the stupid mistake of importing an Eclipse project into my workspace when the import location was from the workspace itself. I went to delete the recursive folder when I encountered an error that the file path name was too long to delete.

The best manual solution that I found was to go as deep as possible in the recursive folder and then map it to a virtual drive.


subst x: c:\recursiveFolder\recursiveFolder\recursiveFolder\...


This can be quite an arduous process; I found myself creating up to 9 virtual drives. It eventually worked though and I was able to delete the recursive folder.


I also found a site with a Perl script that deletes long file paths but haven't tested it myself.

2 comments:

  1. If you have a problem in moving the long path file then try long path tool. Currently am using it.

    ReplyDelete
  2. Sounds good. Is this site you are referring to?
    http://longpathtool.com/

    ReplyDelete