I have some folders and files that do not get deleted in the trash folder.
I logged in as root using
sudo su
then
rm -rf ~/.local/share/Trash/files/*
but nothing happens.
Can anyone help with a step-by-step solution please?
root's Trash directory?
I assume you want to empty your user's trash, not root's. If you "sudo su" then "~" will (probably[0]) expand to "/root", which is unlikely to be what you meant.
Why are you using sudo to do this anyway?
If you need to be root (for some reason) to delete these files, try:
sudo rm /home/<username>/.local/share/Trash/files/*
or similar.
[0] whether it does or not depends on how much of the environment gets inherited when sudo is run, but I think by default it does
rm -rf /home/<username>/.local/share/Trash/files/*
.... I.e. the rm -r
command is to be used for deleting folders.
Jul 19, 2016 at 18:19
rm
command you're trying to run is to delete the files. Can you clarify what you're trying to do?