Feature Request: Advanced Web.config Transformations

Nov 22, 2010 at 1:36 PM

Hey all,

At my company, we're looking to use NuGet for our corporate libraries.  We really see the value in having everything contained in a package.  Being able to cherry-pick whatever we need for each project is a great benefit.  We have a few libraries, however, that require some more advanced changes to the Web.config file.  One of the features we've used quite a bit is the ability to transform our "Release mode" config files when deploying our projects.

I'd like to request that this feature is added to NuGet.  Maybe you could even call the existing transform program from the command line when certain transform files exist in the content folder.  The problem ultimately is that the current transform system just isn't powerful enough for us.  For example, I need to be able to add the "behaviorConfiguration" attribute to all existing WCF service references in a Web.config file, and I just don't see an easy way to do this.  Sure I could write a custom powershell cmdlet to handle it for me, but we'd still have to remember to invoke it.  It certainly would be easier if the more advanced config transformations from ASP.NET were available in NuGet.

Thanks for such an awesome project.  We're loving it so far!

Scott

Coordinator
Nov 22, 2010 at 3:49 PM

We have plans to look at more powerful configuration transformations in the future.

Sure I could write a custom powershell cmdlet to handle it for me, but we'd still have to remember to invoke it.

Actually, if you call the cmdlet from an Install.ps1 file within your package, it'll automatically run when you install the package.