Error while running batch scripts 'Error message highlight pattern:' - tfs-2015

I am trying to do a ms, xcopy and other cmd commands in TFS 2015 vNext builds but I am getting the error
Error message highlight pattern:
Warning message highlight pattern:
Please help

I resolved this problem by changing the batch task tool value from cmd.exe to powershell.exe. In this case the error was same but the task did the job.

Related

SqlPackage Publish stops on error: An insufficient number of arguments were supplied for the procedure or function

I have a Visual Studio Database Project, containing whole database. Build passes without errors, but when I try to deploy the DACPAC to a database, the SqlPackage Publish stops on the following error:
An insufficient number of arguments were supplied for the procedure or function
There are some build warnings, but no warning describing the mentioned error.
Why is not the error thrown during build? Why is not the error thrown during build? Why is the error stopping deployment even if the build passed without error? It's too late, it should be catched during build IMHO.
Please is there anything I can do, some settings etc. that catches the error during build?
Thank you.

TFS 2015 Command Line build task fails after executing xUnit tests but there's no error/issue

In the build definition in TFS 2015, I've got a Command Line step that runs the following command:
xunit.console.exe \PathToTests\Tests.dll -xml \PathToResultsFolder\Results.xml
During the build, I can see the tests are being discovered and executing and everything's looking good.
But if I don't check "Continue on error" in the Command Line step, after the tests run and the result XML file has been saved, the step fails with the following error:
Task CmdLine failed. This caused the job to fail. Look at the logs for the task for more details.
But there's actually no error or anything I can see. The tests have run and the XML file has saved properly and is able to published to TFS. And I don't see an error like this if I run the command from the build machine.
Any ideas?

MSBuild throws 'name too long' on project if called from Jenkins but not CMD

If I run the following command manually everything compiles fine.
cd D:\Jenkins\[redacted]\Api>
C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe /property:Configuration=Release Api.sln
If I run the same command (copy/paste) from Jenkins MSBuild gives me the following error for one of my projects
"D:\Jenkins\[Redacted]\Logic\[Redacted].Api2.Logic.csproj" (default target) (26) ->
(GenerateSatelliteAssemblies target) ->
ALINK : error AL1061: Cannot set option 'description' because 'The file name is too long. '
Why does the MSBuild work when running through the CMD but not via Jenkins? It doesn't look like a permissions issue and only one project out of many that hasn't been touched in months breaks.
Even the error message is a little odd - There is no description in the assemblyinfo and there are much longer file names that compile without issues in the solution.
What could be causing this? The best I could find is this http://connect.microsoft.com/VisualStudio/feedback/details/728795/error-al1061-when-building-satellite-assemblies-with-long-names which was of no use.

error MSB3073: Visual studio 2010, windows7

error MSB3073: The command "
if "%OS%"=="" goto NOTNT
if not "%OS%"=="Windows_NT" goto NOTNT
"EventController.exe" /RegServer
echo regsvr32 exec. time > "UnicodeDebug\regsvr32.trg"
echo Server registration done!
goto end
:NOTNT
echo Warning : Cannot register Unicode EXE on Windows 95
:end
:VCEnd"
exited with code 9009.
How to handle this error. Help is appreciated, thanks
OK, this is mostly guesswork, but I'm feeling adventurous today :-)
Based on the bad formatting of your code fragement (which I liberally adjusted) it is a bit hard to tell, but the most likely cause is that a command was not found.
Background:
What you have here is not c++ code and has as such nothing to do with compilation. Again I took the liberty to change the tags accordingly. It is a batch (fragment), which from the error code MSB.... seems to be executed by MSBuild during your build process, which might be the reason why you "assumed" it has something to do with C++ or the compiler.
Now, the actual clue lies in the exit code "9009" which is the same error code that you get when you try to invoke a command / executable, that does not exist or cannot be found, from the command prompt.
So, most likely one of the commands in the fragment you show does not exist or cannot be found. I would assume it is the "EventController.exe" executable.

Unexpected System.Reflection.TargetInvocationException error executing SQL command

MSBUILD - When executing DDL file I get this error:
Unexpected System.Reflection.TargetInvocationException error executing SQL command
Before this execution two other ones are executed with no problems.
I'm assuming that you're using the ExecuteDDL task from the MSBuild Community Tasks library. If so, I've run into the same issue before and I have always found that the script fails if I run it manually in SQL Management Studio.
I recommend that you run the two scripts that succeeded, then running the on that's failing manually and make sure that it doesn't have any errors.