-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can I replace part of a value? #200
Comments
Anyone? |
SlowCheetah uses |
Replacing a portion of the value is not supported with XDT out of the box. It is possible to create a custom XDT transform which can replace a portion of an attribute value. I describe how to do this in an old blog post at http://sedodream.com/2010/09/09/extendingxmlwebconfigconfigtransformation.aspx. With that said, I've never tested using a custom transform with SlowCheetah. Also @jviau and others are in the middle of refactoring the code, so if you get it working now you may need to update a reference later. |
All of the examples I've seen of using SlowCheetah involve replacing the full contents of an attribute in a node.
What I want to do is replace part of an attribute value. For example, if my App.config file contains the following...
...then I can add a transform to my App.Release.config file as follows...
...and it will produce the correct output.
However, as I have a lot of these service references, I have lots of entries like the above in the App.config file, with corresponding entries in the App.Release.config file.
What I would really like to do is only have to add one entry to the App.Release.config file that works all of the service entries in the App.config file, ie it transforms localhost:24953 into www.mydomain.co.uk for each node in the file.
Is this possible, or do I have to have a separate entry in my App.Release.config file for every service?
The text was updated successfully, but these errors were encountered: