Skip to content

Commit

Permalink
Removed clean task and only do this in the uploadDocs task
Browse files Browse the repository at this point in the history
  • Loading branch information
flemming-n-larsen committed Feb 12, 2025
1 parent dba530c commit b5acba9
Showing 1 changed file with 12 additions and 14 deletions.
26 changes: 12 additions & 14 deletions buildDocs/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,6 @@ node {
}

tasks {
clean {
doLast {
delete(fileTree("../docs").matching {
exclude("api/**")
})
delete(
"docs/.vuepress/.cache",
"docs/.vuepress/.temp",
"docs/.vuepress/dist"
)
}
}

// Install or update to `docfx`
val updateDocfx by registering(Exec::class) {
commandLine("dotnet", "tool", "update", "-g", "docfx", "--version", "2.77.0")
Expand All @@ -44,9 +31,20 @@ tasks {
}

val uploadDocs by registering(Copy::class) {
dependsOn(clean, npmBuild)
dependsOn(npmBuild)
dependsOn(updateDocfx)

doFirst {
delete(fileTree("../docs").matching {
exclude("api/**")
})
delete(
"docs/.vuepress/.cache",
"docs/.vuepress/.temp",
"docs/.vuepress/dist"
)
}

duplicatesStrategy = DuplicatesStrategy.EXCLUDE

from("build/docs")
Expand Down

0 comments on commit b5acba9

Please sign in to comment.