diff options
author | Kamil Doległo <kamilok1965@interia.pl> | 2020-06-12 12:45:22 +0200 |
---|---|---|
committer | Paweł Marks <pmarks@virtuslab.com> | 2020-06-12 14:15:24 +0200 |
commit | ea03d377badb165869728ce6ecc9ad3c0fdbe70b (patch) | |
tree | 0886a33d3d3ccb8c4c4336c0c35dada3a662b453 /plugins/base/frontend/build.gradle.kts | |
parent | a02927ee0d9cc77c0730e4fb0dc8968b912a64fe (diff) | |
download | dokka-ea03d377badb165869728ce6ecc9ad3c0fdbe70b.tar.gz dokka-ea03d377badb165869728ce6ecc9ad3c0fdbe70b.tar.bz2 dokka-ea03d377badb165869728ce6ecc9ad3c0fdbe70b.zip |
Fix npm caching
Diffstat (limited to 'plugins/base/frontend/build.gradle.kts')
-rw-r--r-- | plugins/base/frontend/build.gradle.kts | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/plugins/base/frontend/build.gradle.kts b/plugins/base/frontend/build.gradle.kts index d1141a4c..c1654f99 100644 --- a/plugins/base/frontend/build.gradle.kts +++ b/plugins/base/frontend/build.gradle.kts @@ -2,17 +2,18 @@ plugins { id("com.moowork.node") version "1.3.1" } -task("generateFrontendFiles") { - dependsOn("npm_install", "npm_run_build") -} - tasks { - "npm_run_build" { - inputs.dir("$projectDir/src/main/components/") + val npmRunBuild by registering { + inputs.dir("$projectDir/src/main/") inputs.files("$projectDir/package.json", "$projectDir/webpack.config.js") outputs.dir("$projectDir/dist/") } + + register("generateFrontendFiles") { + dependsOn(npmInstall, npmRunBuild) + } + clean { - delete = setOf("$projectDir/node_modules", "$projectDir/dist/", "$projectDir/package-lock.json") + delete = setOf("$projectDir/node_modules", "$projectDir/dist/") } -} +}
\ No newline at end of file |