here's the scene:
We use Visual Studio Online and an on-premise build server in our company network with TFS 2013 to build our solution after gated check-ins and releases.
Now we upgraded from Visual Studio 2013 to Visual Studio 2015 Enterprise and upgraded to the new .NET version. We are were really eager to make use of the new features of C# 6 but after the first check-in we experienced that the build failed.
(Sorry no image here as I have a lack of reputation)
Exception Message: MSBuild error 1 has ended this build. You can find
more specific information about the cause of this error in above
messages. (type BuildProcessTerminateException) Exception Stack Trace:
at System.Activities.Statements.Throw.Execute(CodeActivityContext
context) at
System.Activities.CodeActivity.InternalExecute(ActivityInstance
instance, ActivityExecutor executor, BookmarkManager bookmarkManager)
at
System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor
executor, BookmarkManager bookmarkManager, Location resultLocation)
ApplicationManager.cs (33, 0) Unexpected character '$'
ApplicationManager.cs (33, 0) ; expected
It seems that the build agent does not understand the new syntax and still compiles with old version.
What I did in order to fix it was:
Which is basically installing Visual Studio 2015 and the new Microsoft Build Tools
- And the steps in here which were very promising:
I created a new build definition with one of the templates
Created a new agent pool via the web access for Visual Studio Online. Downloaded
the ConfigureAgent.ps1 and executed it on the build server to create a new
agent. But I couldn't figure out how to make use of the newly created agent.
My question is: How can I update the build agents to run without failure in
respect to the new .NET version?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…