def compress_value(value):
    """
    Converts (('buildout', 'directory'), '/something/something) into
    ${buildout:directory}/something/something
    """
    data_list = []
    for elem in value:
        if isinstance(elem, tuple):
            data_list.append('${%s:%s}' % elem)
        else:
            data_list.append(elem)
    return ''.join(data_list)