I have a web project (ASP.NET MVC 4 project) that has a number of configurations stored in Web.Config and in NLog.config files.
I have
I've managed it without moving all configuration into web.config or app.config. (There is nothing, connected with nlog in web/app.config at all).
1) Using this article: applying msbuild config transformations to any config file I've created all transformations, which are necessary and added transformation task.
2)Then I've checked if there are any other tasks, which do similar things. In my case there was one, which had been created by SlowCheetah(VS extension to automatically add transformations). I've removed it - and everything became ok. (SlowCheetah can restore its settings on next build, so it is better to remove it or suppress its transformation task)
3) My transform files look like this one: