msbuild - Continuous integration AND NuGet restore in VSO and Azure -


we using vso , azure cloud services (web roles).

previously, have used following build.proj file our vso build definitions:

<?xml version="1.0" encoding="utf-8"?> <project toolsversion="4.0" defaulttargets="build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">   <propertygroup>     <outdir>$(msbuildthisfiledirectory)bin</outdir>     <configuration>release</configuration>     <projectproperties>outdir=$(outdir);configuration=$(configuration);</projectproperties>   </propertygroup>   <itemgroup>     <solution include="$(msbuildthisfiledirectory)*.sln" />   </itemgroup>   <target name="restorepackages">     <exec command="&quot;$(msbuildthisfiledirectory).nuget\nuget.exe&quot; restore &quot;%(solution.identity)&quot;" />   </target>   <target name="clean">     <msbuild targets="clean" projects="@(solution)" properties="$(projectproperties)" />   </target>   <target name="build" dependsontargets="restorepackages">     <msbuild targets="build" projects="@(solution)" properties="$(projectproperties)" />   </target>   <target name="rebuild" dependsontargets="restorepackages">     <msbuild targets="rebuild" projects="@(solution)" properties="$(projectproperties)" />   </target> </project> 

the reason execute nuget restore before msbuild began running. suggested approach nuget.

now trying set continuous integration our azure cloud services, instructed in this msdn article.

this means must use tfvccontinuousdeploymenttemplate.12.xml build process template.

but when setting template build build.proj file, following build error occurs:

exception message: deploying azure cloud service requires visual studio solution (.sln) contains either ccproj or lsxproj. (type deploymentexception) exception stack trace:    @ system.activities.statements.throw.execute(codeactivitycontext context)    @ system.activities.codeactivity.internalexecute(activityinstance instance, activityexecutor executor, bookmarkmanager bookmarkmanager)    @ system.activities.runtime.activityexecutor.executeactivityworkitem.executebody(activityexecutor executor, bookmarkmanager bookmarkmanager, location resultlocation) 

when using .sln, works fine. need nuget restore occur before build.

what solution have both continuous integration , nuget restore working?

i have learnt redundant. there no reason manually execute nuget restore built vso/tfs.

read more here.


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -