Don’t forget the dot files and directories. Use sudo in case of trouble…sudo rm -rf .*
Oh god, I never considered that .* could theoretically match . Thanks fish for not doing that, more than likely saved my unknowing ass a couple of times
Someone please find me an example of a real shell that does this cuz I don’t believe it.
It happened to me once. It was probably an old version of bash or possibly even just sh.
When your wiping recycle bin and then run that command…
Oh god…why would you not just cd … and rm -r the directory name?
Because you don’t always want to delete the directory itself, to then recreate it and set the ownerships and permissions again
Fair enough. Then why not cd …, rm ./dir_name/* ?
because that does not delete hidden files in the directory
Fair enough. Why not tack on rm ./.* as well to that list? Lol. Sorry, I’m truly just curious and not trying to be a smart alec.
with that we arrive at the original problem: depending on your shell and its configuration, could be part of the results of the glob expansion. so at that point why bother stepping one dir level up
Ah I see. Very interesting! Thank you.