linux delete files more than one code example
Example 1: delete all the files without one in linux
# delete all except the filename
$ rm -v !("filename")
Example 2: linux delete files in folders without deleting the folder
find /path/to/directory -type f -exec rm -iv {} \;