Normally you could use a simple “rm” command in Unix/Linux. But sometimes if the folder is very full of files you may get the error:
“Argument list too long”
In which case you could use the “find” command instead:
find -name "*" -delete
This will delete all files, to pattern match a certain type of file (like PDF files):
find -name "*.pdf" -delete
Delete all Files in a Unix Folder when “Argument list too long”