Getting around Too Many Args error

Some Linux applications such as rm have a maximum limit on the number of files which they can process. To get around this limit you can use the following command:

find $directory -name '*' -exec rm {} \;

Replace $directory with the name of the directory you want to clean out and this command will remove everything in the directory regardless of how many items there are.