From 44167608225167e1692f2ab388aefe5fa27482b7 Mon Sep 17 00:00:00 2001 From: Rob Murdock Date: Sat, 8 Jul 2023 21:07:38 -0400 Subject: [PATCH] restoring server stats task --- server/build.gradle.kts | 29 +++++++++++++++-------------- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/server/build.gradle.kts b/server/build.gradle.kts index c46e4de75c..3248e04c4d 100644 --- a/server/build.gradle.kts +++ b/server/build.gradle.kts @@ -114,20 +114,21 @@ tasks { workingDir = file("${rootProject.buildDir.resolve("js").resolve("packages/Coupling-server")}") } -// register("serverStats") { -// dependsOn(compileKotlinJs, processResources, compileProductionExecutableKotlinJs) -// mustRunAfter(clean) -// -// nodeCommand = "webpack" -// arguments = listOf( -// "--config", -// project.projectDir.resolve("webpack.config.js").absolutePath, -// "--profile", -// "--json=${rootDir.absolutePath}/compilation-stats.json" -// ) -// environment("NODE_ENV" to "production") -// workingDir = file("${rootProject.buildDir.resolve("js").resolve("packages/Coupling-server")}") -// } + register("serverStats") { + setup(project) + dependsOn(compileKotlinJs, jsProcessResources, compileProductionExecutableKotlinJs) + mustRunAfter(clean) + + nodeCommand = "webpack" + arguments = listOf( + "--config", + project.projectDir.resolve("webpack.config.js").absolutePath, + "--profile", + "--json=${rootDir.absolutePath}/compilation-stats.json" + ) + environment("NODE_ENV" to "production") + workingDir = file("${rootProject.buildDir.resolve("js").resolve("packages/Coupling-server")}") + } val copyServerIcons by registering(Copy::class) { from("public")