def camelToSnake(s):
_underscorer1 = re.compile(r'<STR_LIT>')<EOL>_underscorer2 = re.compile('<STR_LIT>')<EOL>subbed = _underscorer1.sub(r'<STR_LIT>', s)<EOL>return _underscorer2.sub(r'<STR_LIT>', subbed).lower()<EOL>
https://gist.github.com/jaytaylor/3660565
Is it ironic that this function is written in camel case, yet it
converts to snake case? hmm..