Ubuntu – Why can’t I delete a folder in the trash

command linedeletejavaminecrafttrash

So I downloaded a "cracked" version of Minecraft. STUPID, I know and understand the dangers. Anyway, the download put a folder called "minecraft" on my computer. it contained a .png and a .jar file. the folder was locked and ended up buying Minecraft from Mojang. Then came the problem of deleting this file. It told me I didn't have the permissions to delete the file. I used the command:

Sudo nautilus

This managed to move the folder to trash. Now when I go to empty trash it says "ERROR WHILE DELETING". The file doesn't get deleted…. Any suggestions, tips, tricks, etc would be fantastic! 🙂

Best Answer

Try this:

sudo rm -rf ~/.local/share/Trash/*

Of course replace the * with the folder that you wish to delete or else everything in the trash will be deleted.

Related Question