remove the useless files and directories.