Can't get rid of desktop.ini file in Unity project

1.3k views Asked by At

I recently had to move my unity project over to google drive for a couple weeks so I could continue work on my game. After moving it to google drive, windows 10 starting adding a desktop.ini file to all of the directories in the project folders. I have moved my project back to my desktop hard drive and I deleted all of the desktop.ini files. For some reason when I try to build my project I get an error that says "Invalid resource directory" and points to the path in my android-resources folder where a desktop.ini file keeps getting generated. It doesn't matter if I delete it or not because it gets generated every time I try to build the project. Any ideas?

1

There are 1 answers

4
Berzi Wasfy On BEST ANSWER

Cloud storage is known for producing desktop.ini files with accompanying problems. When Windows creates a desktop.ini in a folder that Unity is attempting to package you'll get the "Invalid Resource Directory" error since it tries to bundle a file it doesn't expect.

You must prevent desktop.ini files from being generated. There are different methods but no guaranteed solutions. Try this registry change: http://jamesisin.com/a_high-tech_blech/index.php/2010/09/nevermore-be-bothered-by-desktop-ini/

Then move your project to another directory (make sure you've turned off any cloud Storage or similar as well).

If that doesn't work try finding other options for turning off desktop.ini generation. Good luck!