src/tablemate/config.py
def locations(exists=True, extras=None):
    """Return the location of the config file(s)."""
    result = []
    candidates = [
        '/etc/{}.conf'.format(APP_NAME),
        os.path.join(click.get_app_dir(APP_NAME) + '.conf'),
    ] + (extras and list(extras) or [])

    for config_file  in candidates:
        if config_file and (not exists or os.path.exists(config_file)):
            result.append(config_file)

    return result
Return the location of the config file(s).
Return the location of the config file(s).
Return the location of the config file ( s ) .
def locations(exists=True, extras=None):
    result = []
    candidates = [
        '/etc/{}.conf'.format(APP_NAME),
        os.path.join(click.get_app_dir(APP_NAME) + '.conf'),
    ] + (extras and list(extras) or [])
    for config_file  in candidates:
        if config_file and (not exists or os.path.exists(config_file)):
            result.append(config_file)
    return result
def locations ( exists = True , extras = None ) : result = [ ] candidates = [ '/etc/{}.conf' . format ( APP_NAME ) , os . path . join ( click . get_app_dir ( APP_NAME ) + '.conf' ) , ] + ( extras and list ( extras ) or [ ] ) for config_file in candidates : if config_file and ( not exists or os . path . exists ( config_file ) ) : result . append ( config_file ) return result
Return the location of the config file(s).
Return the location of the config file ( s ) .
"""Return the location of the config file(s)."""
exists
extras