Macos – Command to remove all files and folders recursively including, hidden ones, on MAC OS Terminal

macosrm

rm -rf * will remove all files and folders but not hidden ones.

rm -rf .* will remove all hidden files and folders, but not those that are not hidden, correct?

What command should one type, in order to delete all files and folders including the hidden ones? (except . and ..); ?

Best Answer

rm -rf * .*

will do the trick.

Related Question