improve logging
authorEugene.Petrenko <eugene.petrenko@gmail.com>
Sat, 9 Jul 2011 09:37:18 +0000 (13:37 +0400)
committerEugene.Petrenko <eugene.petrenko@gmail.com>
Sat, 9 Jul 2011 09:37:18 +0000 (13:37 +0400)
nuget-agent/src/jetbrains/buildServer/nuget/agent/install/PackagesInstallerRunner.java

index 7d11d07973389c73f0193a4fc9f4a55e224609a8..9d89e573c565ed945b4d76796b21b306e81957cd 100644 (file)
@@ -23,6 +23,7 @@ import jetbrains.buildServer.nuget.agent.util.DelegatingBuildProcess;
 import jetbrains.buildServer.nuget.agent.util.impl.CompositeBuildProcessImpl;\r
 import jetbrains.buildServer.nuget.common.DotNetConstants;\r
 import jetbrains.buildServer.nuget.common.PackagesInstallerConstants;\r
+import jetbrains.buildServer.util.FileUtil;\r
 import org.jetbrains.annotations.NotNull;\r
 \r
 import java.io.File;\r
@@ -74,7 +75,9 @@ public class PackagesInstallerRunner implements AgentBuildRunner, AgentBuildRunn
 \r
                           @NotNull\r
                           public BuildProcess startImpl() throws RunBuildException {\r
-                            logger.activityStarted("install", "Installing NuGet packages for " + config, "nuget");\r
+                            String pathToLog = FileUtil.getRelativePath(context.getBuild().getCheckoutDirectory(), config);\r
+                            if (pathToLog == null) pathToLog = config.getPath();\r
+                            logger.activityStarted("install", "Installing NuGet packages for " + pathToLog, "nuget");\r
 \r
                             return myInstallActionFactory.createBuildProcess(context,\r
                                     parameters,\r