>>> import schlarp.chaz

Posts

Stupid CloudFormation Tricks #1: String replacement and changing case

(Note: I work for AWS, but this article is my own opinion as an avid CloudFormation user. I don’t work on the CloudFormation team, and I have no insight into their roadmap or operations.) A commonly supported operation in general-purpose programming languages is “string replacement”, in which all occurrences of a given substring are replaced with another. For example, string replacement in Python looks like this: >>> 'tart'.replace('t', 'b') 'barb' String replacement without macros CloudFormation isn’t a general-purpose programming language and doesn’t offer this functionality, even though we might want it on occasion.

Read more »