deleteRecursively

fun File.deleteRecursively(): Boolean (source)

Platform and version requirements: JVM

Delete this file with all its children. Note that if this operation fails then partial deletion may have taken place.

Return true if the file or directory is successfully deleted, false otherwise.