From 0ba928cde136647f2ee9eb0a2319e4258996bc92 Mon Sep 17 00:00:00 2001 From: Chris Blyth Date: Thu, 27 Sep 2018 09:25:15 +0100 Subject: [PATCH] Error messages are sent to TeamCity with status ERROR --- src/app/Fake.BuildServer.TeamCity/TeamCity.fs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/app/Fake.BuildServer.TeamCity/TeamCity.fs b/src/app/Fake.BuildServer.TeamCity/TeamCity.fs index 48b806821fe..45a86df9e07 100644 --- a/src/app/Fake.BuildServer.TeamCity/TeamCity.fs +++ b/src/app/Fake.BuildServer.TeamCity/TeamCity.fs @@ -222,6 +222,10 @@ module TeamCity = let internal warning message = TeamCityWriter.sendToTeamCity "##teamcity[message text='%s' status='WARNING']" message + /// Sends a warning message. + let internal error message = + TeamCityWriter.sendToTeamCity "##teamcity[message text='%s' status='ERROR']" message + /// TeamCity build parameters /// /// See [Predefined Build Parameters documentation](https://confluence.jetbrains.com/display/TCD18/Predefined+Build+Parameters) for more information @@ -403,7 +407,7 @@ module TeamCity = | TraceData.ImportantMessage text -> warning text | TraceData.ErrorMessage text -> - ConsoleWriter.write false color true text + error text | TraceData.LogMessage(text, newLine) | TraceData.TraceMessage(text, newLine) -> ConsoleWriter.write false color newLine text | TraceData.ImportData (ImportData.BuildArtifactWithName _, path)