Hi, with the version of Microsoft.Web.XmlTransform.dll used by the task I have some problems because it doesn't support the replace of a root element having attributes that instead is supported by the latest version, used by visual studio too (https://www.nuget.org/packages/Microsoft.Web.Xdt/).
I downloaded and tried the latest version (v3.1.0) for .net 4 using the API required by your task and I haven't found any breaking changes (I used c# because I'm not very good with ps :) )
var source = new Microsoft.Web.XmlTransform.XmlTransformableDocument { PreserveWhitespace = true }; source.Load(sourceFile); var transform = File.ReadAllText(transformFile); var transformation = new Microsoft.Web.XmlTransform.XmlTransformation(transform, false, null); transformation.Apply(source); source.Save(outputFile);
I don't know gulp but, if it's possible, maybe a better way is to download the dll from the nuget package within the gulp build script so the dll isn't included in this git rep
Hi, with the version of Microsoft.Web.XmlTransform.dll used by the task I have some problems because it doesn't support the replace of a root element having attributes that instead is supported by the latest version, used by visual studio too (https://www.nuget.org/packages/Microsoft.Web.Xdt/). I downloaded and tried the latest version (v3.1.0) for .net 4 using the API required by your task and I haven't found any breaking changes (I used c# because I'm not very good with ps :) )
var source = new Microsoft.Web.XmlTransform.XmlTransformableDocument { PreserveWhitespace = true }; source.Load(sourceFile); var transform = File.ReadAllText(transformFile); var transformation = new Microsoft.Web.XmlTransform.XmlTransformation(transform, false, null); transformation.Apply(source); source.Save(outputFile);
I don't know gulp but, if it's possible, maybe a better way is to download the dll from the nuget package within the gulp build script so the dll isn't included in this git rep