This package enables you to transform your app.config or any other XML file based on the build configuration. It also adds additional tooling to help you create XML transforms.. Written by: Sayed Ibrahim Hashimi, Chuck England and Bill Hiebert
I am extremely frustrated with SlowCheetah. I tried to use it in many occasions and it never quite worked for me. The main problem is that I have multiple configurations like: QA, UAT, PRD, Live, Local, DEV, etc and I want to be able to define those myself. Attempting to change the configuration manager of the solution causes an array of problems that need hours to be resolved. Notably, the underlying projects will still not generate the new build configs, which leads to build problems, DLL issues and finally I can't get rid of Debug and Release configurations of which I don't want any configs to be generated. Also if I add my configurations to the configuration manager, How hard is it to let the user define these in a simple XML file? Until this very simple feature is added, SlowCheetah is of no use to me and I assume many other developers
I've been coding large financial trading frameworks in VS/C# since .NET 1.1 days (12/13 years). From this perspective, I can affirmatively state that Slow Cheetah is by far the most productive package that is not currently integrated into the VS tool. I'm walking through a major rollout now involving five different staging environments and over twenty different server configs. Without Slow Cheetah, the other 35 people in the deployment team waiting on my builds would be left high and dry while I tried to manage the configs by hand. VS management - what the *hell* are you thinking? Integrate!
Thanks for this cool tool!
Questions (VS2012 update 4):
1 - No "Preview Transform" on "Web.Release.config". I do get it when I right-click on the Debug config. Why is that?
2 - I have a separate config for connection strings. I configured profile configs for each, but it doesn't seem the tool picked it up. Do I need to configure this somewhere?
Is there some way to preserve the format of the original config file?
We've got the VS option "Align attributes each on separate line" for XML files
But after running a web config transform, the replaced section goes back to a single line
I have a problem with log4net config files not being updated by SlowCheetah in Visual Studio 2010. I'm using SlowCheetah 18.104.22.168. When I look at diagnostic build output, I receive the message:
Task "SlowCheetah.Xdt.TransformXml" skipped, due to false condition; (Exists('%(RelativeDir)%(Filename).$(Configuration)%(Extension)')
and '%(Link)'!='' ) was evaluated as (Exists('Log4Net.Prod.config')
and '' != '').
I have two questions:
1) Where is SlowCheetah getting the "Prod" configuration from? I'm using the "Release" build profile in Visual Studio 2010.
2) In the csproj file for my project, I see no references to a "<Link>" element but the log4net config file is referenced in a "<None>" element. Clearly Slowcheetah is finding the log4net.config file to attempt the transformation but won't the fact that there is no <Link> element always prevent the transformation from happening?
I want to create transforms for each of our environments (e.g. "Dev", "QA", "Prod") and name them accordingly. Having transforms named after the build configuration (e.g. "Debug" or "Release") doesn't work for us. How can I set that up?
Sorry Michael for the intrusion but I had the same issue.
I already did what you suggested but still only Debug and Release are getting transformed. Once I use the environment specific config, the environment specific config files is just being copied instead of merging and transforming it with the main app.config.
Apologies for the delay in replying. I'm like you and use 3 different configs (DEV,UAT,PROD) i create these in the build configuration, then right click on the app.config file to create the files app.dev.config etc (I then delete the debug & release versions & build configurations) so the solution only knows about the 3 configs I use, then to build I select the config "dev" and click build solution. This works for me and they seem to get transformed ok - I'm using VS2013.
I want to add transforms to an EPiServer license file. However, for this to be maintainable I need to replace all content in License.config. When I'm adding xdt:Transform="Replace" to the root node I get the following error:
"Could not write Destination file: Cannot insert the node in the specified location."
This applies to any file except Web.config. Any thoughts on this?
Your issue is likely the idea of replacing the root node. Try to alter any available nesting nodes or attributes.
If none of that works you may need to resort to additional post-build steps (if you haven't already).