Skip to content

Commit

Permalink
Create directory
Browse files Browse the repository at this point in the history
  • Loading branch information
BraisGabin committed Dec 26, 2021
1 parent 19b5bb6 commit c038ca7
Showing 1 changed file with 3 additions and 1 deletion.
Expand Up @@ -94,7 +94,9 @@ class DslGradleRunner @Suppress("LongParameterList") constructor(
fun projectFile(path: String): File = File(rootDir, path).canonicalFile

fun writeProjectFile(filename: String, content: String) {
File(rootDir, filename).writeText(content)
File(rootDir, filename)
.also { it.parentFile.mkdirs() }
.writeText(content)
}

fun writeKtFile(srcDir: String, className: String) {
Expand Down

0 comments on commit c038ca7

Please sign in to comment.