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'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!
I really like this tool for Visual Studio (both 2010 and 2013), and cannot understand Microsoft's reluctance to adopt this as a standard feature for all future versions of the IDE.
I found that for me, using the VSIXinstaller for each edition of Visual Studio I'm using, worked well to get it installed. And I have to make sure that custom XML-styled configuration files are marked with "Copy always" or "Copy if newer".
The simple mechanisms for replacing parts of XML that are used by msdeploy on web.config are equally useful with any other config files. SlowCheetah does a great job of extending that functionality in a transparent way to other files.
This extension has saved my countless hours setting up automated builds and continuous deployments. This is a must have if you need to do configuration file transforms during your build and deployment process.
The transforms work as expected for me, but they have broken the Git integration in Visual Studio so that I cannot .gitignore any of the transformations (or at least, when I do, I can't use Visual Studio's git integration).
I need *.Debug.config files to be ignored, because they have developer specific configurations that should not be committed.
This is caused by the ms-persist.xml file that SlowCheetah puts within the .git folder, which Visual Studio then uses as an override to the .gitignore file.
There are various work-arounds to this issue, but ultimately, I'd like SlowCheetah to not put that file into .git at all, so that I can manage my ignores.
new project in Visual Studio, and in a git repo.
Add "app.Debug.config" to .gitignore and save everything.
In Visual Studios "Team Explorer" window, the app.Debug.config shows as a pending change that needs to be committed.
In Git command line, git status does not show app.Debug.config as a pending change.
Like many others here, we're seeing Slow Cheetah fail. It has been working in our web app for several months, allowing us to have different configs, one for release, one for cloud. It would be really nice to have it run on F5, but we can live with it for now.
However last week it suddenly started throwing errors in our build, the MSI is still created but we're getting messages about Slow Cheetah dll not being found. In Visual Studio 2010, I can right button click and "Preview Transform" and it does show me the before and after. However it no longer works when we publish to Azure (we use VS2010 on a deployment box to do that - too small a team to have a dedicated build manager).
Similarly, the regular "Release" transform no longer works on the build server.
I think the time has come for Microsoft to adopt this tool, which is basically sound, and give it the support it deserves.
I have an xml file as an embedded resource to be used for nhibernate configuration. I would like to embed the transformed file as the embedded resource rather than the original. Since the transformed files are copied in to the relative bin\$(Configuration) the build will and does include the non transformed file as the embedded resource. I was wondering if there is a simple way using "Slow Cheetah" to get the transformed file included as the embedded resource.
One way would be to run the transforms before the build begins and add the xml file as a Link from the bin\$(Configuration) so that you always get the transformed file rather that the original.
Hello Sayed and Kamran,
I am not at all familiar with msbuild tasks, but I also have the need to transform embedded .resx files and .settings files. Do either of you have suggestions how to modify the .csproj file to accomplish this?
I tried to build an asp.net project including slowsheetah 220.127.116.11 version and i got the following build error:
error MSB3191: Unable to create directory "C:\Windows\system32\config\systemprofile\AppData\Local\Microsoft\MSBuild\SlowCheetah\v18.104.22.168\"
Although the slowcheeta files are not located there.
When i replaced the line in the slowcheeta.transforms.targets file:
so, are you going to modify your that file or i miss something to be added?
fyi: similar issue at: https://github.com/sayedihashimi/slow-cheetah/issues/118.
i testing your package. It's great!!!
One question, when I package a worker role it doesn't copy the transformed App.config to the package. How can i fix it?
PD: I'm using visual studio 2013 (update 1)
Nor effective transformation nor transform preview works when I use your custom extended transformation attribute described at http://sedodream.com/default,date,2010-09-09.aspx which indeed works like acharm ;).
Here is the result of the build :
Build started 21/06/2012 17:21:32.
A TargetFramework profile exclusion list will be generated.
Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
Skipping target "_CopyAppConfigFile" because all output files are up-to-date with respect to the input files.
ConsoleApplication1 -> d:\rzetelny\Visual Studio 2010\Projects\ConsoleApplication1\bin\Debug\ConsoleApplication1.exe
Transforming Source File: d:\rzetelny\Visual Studio 2010\Projects\ConsoleApplication1\App.config
Applying Transform File: App.Debug.config
d:\rzetelny\Visual Studio 2010\Projects\ConsoleApplication1\App.Debug.config(10,10): error : Could not resolve 'AttributeRegexReplace' as a type of Transform
d:\rzetelny\Visual Studio 2010\Projects\ConsoleApplication1\App.Debug.config(14,10): error : Could not resolve 'AttributeRegexReplace' as a type of Transform
Is there a way to make them work together ?
We have a shared config file across multiple projects, We use a link to the Root App.config file and another CustomConfig.config file which are used all over the place when i click on AddConfig Transforms it shows me a dialog box.
"Add as linked configs?"
Press yes then it says
"Object reference not set to an instance of an object."
Any idea on what could be happening at this point?
I was trying to add config files that were not debug or release for my other environments. I didn't see any way through VS to do this, so I decided to edit the project files. I added a PropertyGroup setting as well as an ItemGroup setting in my project file. The new config did show up under the app.config, however the actual build for my selected config did not transform the configuration or put the built files into the same named folder under bin. Suggestions? Is there a limitation to only debug and release builds? Thanks
I have build the transform replacement using the plungin on a Class Library project and it works amazingly on my box. I checked everything into SVN and everyone who got the project from SVN are unable to get the replacements to work. I have the following setup..
App.Debug.QA2.config We checked a few things.. everyone has the plung-in installed, we are all on VS2013 Pro, our project files (XMLs) are good, we are all selecting the correct environment (QA1/QA2) build configuration when we build but for everyone else the <dllname>.config file is not getting replaced. any inputs?
Via Nuget, I've installed SlowCheetah 22.214.171.124 and SlowCheetah.Tasks.Unofficial 1.0.0, and am unable to add a transform to any of my solution's projects' app.config files. When I right-click on an app.config file, I do not see "Add transform" in the context-sensitive menu that appears.
I have tried uninstalling and reinstalling SlowCheetah and SlowCheetah.Tasks.Unofficial, as well as reloading project, and restarting Visual Studio. None of these have helped.