def remove(self, name): if not name or not name.upper() in self.licenses: raise error.License(error.MISSING, "Trying to remove non existent license %s" % name) name = name.upper() del self.licenses[name] p = fs.join(AIRSTRIP_LICENSES, name) fs.remove(p)
def uninstall(deploy, target, build, name, toolchain = False): globals()['technicolor'] = yawn.get(name) if not technicolor.production: console.error('*NOT* going to remove everything!') return # Start with clean envs env.set(target, build) # Setup the prefixes env.native.prefix = fs.join(deploy, 'Toolchain', target) env.current.prefix = fs.join(deploy, target) # And tmp dirs # env.native.tmp = fs.join(roottmp, 'Toolchain') # env.current.tmp = fs.join(roottmp, target) path = __find(technicolor.production, env.native if toolchain else env.current, ignoresystem = True) if path: console.info("Found tracks of it. Removing production. %s" % path) fs.remove(path) else: console.error("The requested monade is NOT installed. Doing nothing.")