From 3a10919c24cbdf9df7a9bab9b1dda48afb55b5d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Max=20Leuth=C3=A4user?= <1417198+max-leuthaeuser@users.noreply.github.com> Date: Tue, 31 Aug 2021 10:56:03 +0200 Subject: [PATCH] Info logging for long npm/yarn install For: https://github.com/ShiftLeftSecurity/product/issues/8384#issuecomment-909005509 --- .../shiftleft/js2cpg/preprocessing/TranspilerGroup.scala | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/main/scala/io/shiftleft/js2cpg/preprocessing/TranspilerGroup.scala b/src/main/scala/io/shiftleft/js2cpg/preprocessing/TranspilerGroup.scala index 13dc1dc66..9982ffec4 100644 --- a/src/main/scala/io/shiftleft/js2cpg/preprocessing/TranspilerGroup.scala +++ b/src/main/scala/io/shiftleft/js2cpg/preprocessing/TranspilerGroup.scala @@ -29,7 +29,7 @@ class TranspilerGroup(override val config: Config, "@babel/plugin-transform-property-mutators" private def isYarnAvailable: Boolean = { - logger.debug(s"\t+ Checking yarn ...") + logger.debug("\t+ Checking yarn ...") ExternalCommand.run("yarn -v", projectPath.toString) match { case Success(result) => logger.debug(s"\t+ yarn is available: $result") @@ -46,10 +46,11 @@ class TranspilerGroup(override val config: Config, } else { s"npm install --save-dev $BABEL_PLUGINS && ${NpmEnvironment.NPM_INSTALL}" } - logger.debug(s"\t+ Installing plugins ...") + logger.info("Installing project dependencies and plugins. This might take a while.") + logger.debug("\t+ Installing plugins ...") ExternalCommand.run(command, projectPath.toString) match { case Success(_) => - logger.debug(s"\t+ Plugins installed") + logger.debug("\t+ Plugins installed") true case Failure(exception) => logger.debug(s"\t- Failed to install plugins: ${exception.getMessage}")