def get_config_paths():
 config_home = os.environ.get(u'XDG_CONFIG_HOME', os.path.join(os.path.expanduser(u'~'), u'.config'))
 config_path = join(config_home, u'powerline')
 config_paths = [config_path]
 config_dirs = os.environ.get(u'XDG_CONFIG_DIRS', DEFAULT_SYSTEM_CONFIG_DIR)
 if (config_dirs is not None):
  config_paths[:0] = reversed([join(d, u'powerline') for d in config_dirs.split(u':')])
 plugin_path = join(os.path.realpath(os.path.dirname(__file__)), u'config_files')
 config_paths.insert(0, plugin_path)
 return config_paths

def get_config_paths ( ) : config_home = os . environ . get ( u'XDG_CONFIG_HOME' , os . path . join ( os . path . expanduser ( u'~' ) , u'.config' ) ) config_path = join ( config_home , u'powerline' ) config_paths = [ config_path ] config_dirs = os . environ . get ( u'XDG_CONFIG_DIRS' , DEFAULT_SYSTEM_CONFIG_DIR ) if ( config_dirs is not None ) : config_paths [ : 0 ] = reversed ( [ join ( d , u'powerline' ) for d in config_dirs . split ( u':' ) ] ) plugin_path = join ( os . path . realpath ( os . path . dirname ( __file__ ) ) , u'config_files' ) config_paths . insert ( 0 , plugin_path ) return config_paths
get configuration paths from environment variables .