def camelcase_to_slash ( name ) : s1 = re . sub ( '(.)([A-Z][a-z]+)' , r'\1/\2' , name ) return re . sub ( '([a-z0-9])([A-Z])' , r'\1/\2' , s1 ) . lower ( )
python camelcase to dash
Converts CamelCase to camel / case
def camelcase_to_slash(name):
    """ Converts CamelCase to camel/case

    code ripped from http://stackoverflow.com/questions/1175208/does-the-python-standard-library-have-function-to-convert-camelcase-to-camel-cas
    """

    s1 = re.sub('(.)([A-Z][a-z]+)', r'\1/\2', name)
    return re.sub('([a-z0-9])([A-Z])', r'\1/\2', s1).lower()