Contents
How do I delete all empty folders?
Deleting Empty Files and Directories
There are several ways to delete the empty files you find with the above command. The easiest is simply using the find command delete option (-delete). The above will delete all empty directories it finds.
How do I delete an empty directory in terminal?
The way you would remove directories, regardless of whether or not they are empty, type the following command: rm -rf <directory-name> . This will remove the directory, along with all its contents including files and subdirectories.