def make_flags(name, value):
    """
    Given a flag name and its value, return it formatted as Borg-compatible flags.
    """
    if not value:
        return ()
    flag = '--{}'.format(name.replace('_', '-'))
    if value is True:
        return flag,
    return flag, str(value)
