Whenever I try to clean my flutter project by using the command flutter clean I get an error saying
Failed to remove build. A program may still be using a file in the directory or the directory itself. To find and stop such a program, see:
https://superuser.com/questions/1333118/cant-delete-empty-folder-because-it-is-used
My app was working fine and then suddenly this happened, tried running cmd as admin and then cleaning but it didn't work, also restarted the cache from the android studio it didn't work either.
SOLUTION FOR ME
I solved the problem by Shutting down any instances of openJDK or java in task manager, than run it within a cmd window with admin privileges.