I have one C# solution with a few projects in it, in visual studio 2013's post build event of each project, I set up script to sign each dll as following:
call "$(DevEnvDir)..\Tools\vsvars32.bat"
signtool sign /f "$(SolutionDir)mycompany.pfx" /p pwd4Pfx "$(TargetPath)"
Now I configure auto build for the solution in Jenkins using msbuild.exe
I got the following error:
(PostBuildEvent target) ->
C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Microsoft.Common.targets(4291,5): error MSB3073: The command "call "Undefined..\Tools\vsvars32.bat" [C:\Program Files (x86)\Jenkins\workspace\Myproject\Project1.csproj] C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Microsoft.Common.targets(4291,5): error MSB3073: signtool sign /f "C:\Program Files (x86)\Jenkins\workspace\Myproject\mycompany.pfx" /p pwd4pfx "C:\Program Files (x86)\Jenkins\workspace\myproject\project1\bin\Debug\project1.dll" [C:\Program Files (x86)\Jenkins\workspace\myproject\project1\project1.csproj]
How to fix the error in Jenkins? There must be some setting I did wrong. Thanks