'Write a config key from the first config that has it.
If none do, write it to the first one.'

def set(self, key, value):

    assert self.configs
    write_to = None
    for config in self.configs:
        if config.has_key(key):
            write_to = config
    if (write_to is None):
        write_to = self.configs[0]
    write_to.set(key, value)
    logger.debug('Set    %s    in    %s', key, write_to.path)
