At Build Step This is the error I am getting when I build through Jenkins " C:\ProgramFiles\dotnet\sdk\5.0.405\Sdks\Microsoft.NET.Sdk\targets\Microsoft.PackageDependencyResolution.targets(241,5): error NETSDK1004: Assets file ‘C:\ProgramData\Jenkins.jenkins\workspace\DevOpsAPI\src\TimeTracker.DAL\obj\project.assets.json’ not found. Run a NuGet package restore to generate this file. [C:\ProgramData\Jenkins.jenkins\workspace\DevOpsAPI\src\TimeTracker.DAL\TimeTracker.DAL.csproj] "
When I am using “dotnet restore” in command prompt to fix this “error NETSDK1004” it is working but if same command “dotnet restore or MSBuild /t:restore or /t:Restore” giving in Jenkins its displaying “MSBUILD : error MSB1008: Only one project can be specified.”
But In command prompt “dotnet build” command it is working
I am trying to build my DOTNET PROJECT WHICH IS IN GITLAB
Project was cloning correctly from GitLab to my WorkSpace. But After Build I should get “.DLL” Files
but in Jenkins its displaying an Error But if i execute in the command prompt build was a success and .DLL Files are generating
My Expectation is When I click on Build in Jenkins build should be success and “.DLL” Files should be generated