MCPcopy
hub / github.com/corpnewt/gibMacOS / set_prods

Method set_prods

gibMacOS.py:133–149  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

131 title="Error Saving Product Cache")
132
133 def set_prods(self):
134 self.resize()
135 if not self.get_catalog_data(self.save_local):
136 message = "The currently selected catalog ({}) was not reachable\n".format(self.current_catalog)
137 if self.save_local:
138 message += "and I was unable to locate a valid catalog file at:\n - {}\n".format(
139 self.local_catalog
140 )
141 message += "Please ensure you have a working internet connection."
142 if self.interactive:
143 print(message)
144 self.u.grab("\nPress [enter] to continue...")
145 return
146 raise ProgramError(message, title="Catalog Data Error")
147 self.u.head("Parsing Data")
148 self.u.info("Scanning products after catalog download...\n")
149 self.mac_prods = self.get_dict_for_prods(self.get_installers())
150
151 def set_catalog(self, catalog):
152 self.current_catalog = catalog.lower() if catalog.lower() in self.catalog_suffix else "publicrelease"

Callers 1

gibMacOS.pyFile · 0.80

Calls 8

resizeMethod · 0.95
get_catalog_dataMethod · 0.95
get_dict_for_prodsMethod · 0.95
get_installersMethod · 0.95
ProgramErrorClass · 0.85
grabMethod · 0.80
headMethod · 0.80
infoMethod · 0.80

Tested by

no test coverage detected