Provides XDT based transformations for config files.
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.vscode
nuspec/nuget
src
tools
.appveyor.yml
.gitignore
GitReleaseManager.yaml
LICENSE.txt
README.MD
build.cake
build.ps1
setup.cake

README.MD

Cake.XdtTransform

This was adapted from an open issue on Github that shows how to perform an XDT config transform. The issue is still open, but I didn't there would need to be an extra dependency pulled in unless you really needed it and that is why it is still open.

#addin Cake.XdtTransform

var target = Argument("target", "Default");

Task("TransformConfig")
  .Does(() =>
{
  var sourceFile      = File("web.config");
  var transformFile   = File("web.release.config");
  var targetFile      = File("web.target.config");
  XdtTransformConfig(sourceFile, transformFile, targetFile);
});

RunTarget(target);