- Timestamp:
- Apr 5, 2018, 2:58:50 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lliurex-store/trunk/fuentes/python3-lliurex-store.install/usr/share/lliurexstore/storeManager.py
r6693 r7119 17 17 class StoreManager(): 18 18 def __init__(self,*args,**kwargs): 19 self.dbg=False20 19 if 'dbg' in kwargs.keys(): 21 20 self.dbg=kwargs['dbg'] 21 self.dbg=True 22 22 self._propagate_dbg=False 23 23 self.store=None … … 391 391 def _load_Store(self): 392 392 action='load' 393 #Load appstream metada first 394 package_type='*' 395 load_function=self._execute_class_method(action,package_type,launchedby=None) 396 self.store=load_function.execute_action(action=action,store=self.store)['data'] 397 #Once appstream is loaded load the appstream plugins for other package types (snap, appimage...) 393 398 for package_type in self.plugins_registered[action]: 394 load_function=self._execute_class_method(action,package_type,launchedby=None) 395 self.store=load_function.execute_action(action=action,store=self.store)['data'] 399 if package_type!='*': 400 load_function=self._execute_class_method(action,package_type,launchedby=None) 401 self.store=load_function.execute_action(action=action,store=self.store)['data'] 396 402 #def _load_Store 397 403 … … 425 431 result['status']={'status':0,'msg':''} 426 432 for app_info in info_applist: 427 package_type=self._check_package_type(app_info) 428 if package_type in types_dict: 429 types_dict[package_type].append(app_info) 430 else: 431 types_dict[package_type]=[app_info] 433 available_channels=self._check_package_type(app_info) 434 for package_type in available_channels: 435 if package_type in types_dict: 436 types_dict[package_type].append(app_info) 437 else: 438 types_dict[package_type]=[app_info] 432 439 for package_type in types_dict: 433 440 self._debug("Checking plugin for %s %s"%(action,package_type)) … … 613 620 #Zomandos must have the subcategory "Zomando" 614 621 self._debug("Checking package type for app "+app_info['name']) 622 return_msg=[] 623 if app_info['component']: 624 return_msg.append('*') 615 625 if "Zomando" in app_info['categories']: 616 return_msg="zmd" 617 else: 626 return_msg.append("zmd") 618 627 #Standalone installers must have an installerUrl field loaded from a bundle type=script description 619 if app_info['bundle']!='':620 return_msg=app_info['bundle']621 elif app_info['installerUrl']!='':622 return_msg="sh"623 624 return_msg="deb"628 if app_info['bundle']: 629 return_msg.append('bundle') 630 if app_info['installerUrl']!='': 631 return_msg.append("sh") 632 else: 633 return_msg=["deb"] 625 634 return(return_msg) 626 635 #def _check_package_type
Note: See TracChangeset
for help on using the changeset viewer.