Note that there are some explanatory texts on larger screens.

plurals
  1. POMSBuild XmlMassUpdate Task
    text
    copied!<p>I wanted to ask a quick question regarding the behaviour of the MSBuild task XmlMassUpdate.</p> <p>Has anyone found that the task will only copy unique nodes over to the content XML? For example, if I have a client node which has multiple children called endpoint, then it will only mass copy the first endpoint node while eliminating all the others.</p> <p>I've provided some examples below of what I'm describing, many thanks in advance.</p> <p><strong>MSBuild Task:</strong></p> <pre><code>&lt;Project DefaultTargets="Run" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"&gt; &lt;Import Project="$(MSBuildExtensionsPath)\MSBuildCommunityTasks\MSBuild.Community.Tasks.targets" /&gt; &lt;Target Name="Run"&gt; &lt;Delete Condition="Exists('web.config')" Files="web.config"/&gt; &lt;XmlMassUpdate ContentFile="app.config" ContentRoot="configuration/system.servicemodel" SubstitutionsFile="wcf.config" SubstitutionsRoot="/system.servicemodel" MergedFile="web.config" /&gt; &lt;/Target&gt; &lt;/Project&gt; </code></pre> <p><strong>Content:</strong></p> <pre><code>&lt;?xml version="1.0" encoding="utf-8" ?&gt; &lt;configuration&gt; &lt;system.servicemodel/&gt; &lt;/configuration&gt; </code></pre> <p><strong>Replacement:</strong></p> <pre><code>&lt;?xml version="1.0" encoding="utf-8" ?&gt; &lt;system.servicemodel&gt; &lt;client&gt; &lt;endpoint binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_LargeMessage" contract="ClaimsService.IClaimsService" name="WSHttpBinding_IClaimsService"&gt; &lt;/endpoint&gt; &lt;endpoint binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_LargeMessage" contract="LateCertificationAdminService.ILateCertificationAdminService" name="WSHttpBinding_ILateCertificationAdminService"&gt; &lt;/endpoint&gt; &lt;/client&gt; &lt;/system.servicemodel&gt; </code></pre> <p><strong>Output:</strong></p> <pre><code>&lt;?xml version="1.0" encoding="utf-8" ?&gt; &lt;system.servicemodel&gt; &lt;client&gt; &lt;endpoint binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_LargeMessage" contract="ClaimsService.IClaimsService" name="WSHttpBinding_IClaimsService"&gt; &lt;/endpoint&gt; &lt;/client&gt; &lt;/system.servicemodel&gt; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload