Пример #1
0
 def __init__(self, bitHopper):
     self.bitHopper = bitHopper
     pool_configs = []
     for dirpath, dirnames, filenames in os.walk('plugins'):
         for name in filenames:
             try:
                 if name.split('.')[1] == 'cfg':
                     pool_configs.append(os.path.join(dirpath, name))
             except Exception, e:
                 print e
Пример #2
0
 def load_cfg(self):
     """Load all config files from plugin directory"""
     logging.info('Loading Config Files')
     pool_configs = []
     for dirpath, dirnames, filenames in os.walk('plugins'):
         for name in filenames:
             try:
                 if name.split('.')[-1] == 'cfg':
                     pool_configs.append(os.path.join(dirpath, name))
             except Exception, e:
                 logging.info("Unable to load config file for:\n%s \n\n%s") % (dirpath, e)
Пример #3
0
 def load_cfg(self):
     """Load all config files from plugin directory"""
     self.bitHopper.log_msg('Loading Config Files')
     pool_configs = []
     for dirpath, dirnames, filenames in os.walk('plugins'):
         for name in filenames:
             try:
                 if name.split('.')[-1] == 'cfg':
                     pool_configs.append(os.path.join(dirpath, name))
             except Exception, e:
                 print e
Пример #4
0
 def load_cfg(self):
     """Load all config files from plugin directory"""
     logging.info('Loading Config Files')
     pool_configs = []
     for dirpath, dirnames, filenames in os.walk('plugins'):
         for name in filenames:
             try:
                 if name.split('.')[-1] == 'cfg':
                     pool_configs.append(os.path.join(dirpath, name))
             except Exception, e:
                 logging.info("Unable to load config file for:\n%s \n\n%s"
                              ) % (dirpath, e)