Service messages not working in command line script

I am trying to report custom messages inside my inline command custom script :

set sourceRoot=%teamcity.build.workingDir%\Build\Source\TeamWorks\Dev
echo "Testing: ##teamcity[message 'inner']"

echo "##teamcity[message 'NuGet source root is %%sourceRoot%%']"

"%%sourceRoot%%\.nuget\nuget.exe" install "%%sourceRoot%%\TeamWorks.Shared\packages.config" -source "" -o "%%sourceRoot%%\packages" >"%teamcity.build.workingDir%\Build\logs\NuGetPackageRestore.log.txt" 2>&1
"%%sourceRoot%%\.nuget\nuget.exe" install "%%sourceRoot%%\TeamWorks.Client\packages.config" -source "" -o "%%sourceRoot%%\packages" >>"%teamcity.build.workingDir%\Build\logs\NuGetPackageRestore.log.txt" 2>&1


However that does not appear in the output as shown below. Am I misunderstanding this?

[14:11:29][Step 1/3] Starting: D:\TeamCity\buildAgent\temp\agentTmp\custom_script8631894088326309724.cmd

[14:11:29][Step 1/3] in directory: D:\TeamCity\buildAgent\work\f8292870260bc7b1

[14:11:29][Step 1/3] "Testing:

[14:11:29][Step 1/3]

[14:11:29][Step 1/3] "

[14:11:29][Step 1/3] "

[14:11:29][Step 1/3]

[14:11:29][Step 1/3] "

Please sign in to leave a comment.