Solved

Build VS2015 project in bat command

Posted on 2016-09-17
3
122 Views
Last Modified: 2016-09-24
I used to run build the solution using below command

CALL %WINDIR%\Microsoft.NET\Framework\v4.0.30319\MSBuild /t:Build /p:VisualStudioVersion="14.0" "C:/Project/p2/test.sln" /m

But this command get failed...because the solution contain the nuget .It is not getting restored automatically while build solution through above command.
Can anyone have solution for this.?
0
Comment
Question by:Monica P
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 42

Accepted Solution

by:
pcelba earned 500 total points
ID: 41803413
You have to restore nugets explicitly before MCBuild, e.g.

"C:\Program Files (x86)\MSBuild\nuget\nuget.exe" restore YourSolution3.0.sln
0
 
LVL 10

Author Comment

by:Monica P
ID: 41803523
i cannot find nuget folder in the msbuild Folder.So it throws error executing this command..
0
 
LVL 42

Assisted Solution

by:pcelba
pcelba earned 500 total points
ID: 41803670
So you have to download Nuget command line utility from e.g. this link: https://docs.nuget.org/consume/installing-nuget

You may download whatever version will work for you.

Install it in any folder which you may then use before the MSBuild.
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…

634 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question