Make sure that a pecl extension is not installed.

    name
        The pecl extension name to uninstall
975071
def removed(name):
    '''
    
    '''
    ret = {'name': name, 'result': None, 'comment': '', 'changes': {}}
    if name not in __salt__['pecl.list']():
        ret['result'] = True
        ret['comment'] = 'Pecl extension {0} is not installed.'.format(name)
        return ret

    if __opts__['test']:
        ret['comment'] = ('Pecl extension {0} would have been removed'
                          .format(name))
        return ret
    if __salt__['pecl.uninstall'](name):
        ret['result'] = True
        ret['changes'][name] = 'Removed'
        ret['comment'] = ('Pecl extension {0} was successfully removed.'
                          .format(name))
    else:
        ret['result'] = False
        ret['comment'] = 'Could not remove pecl extension {0}.'.format(name)
    return ret
129612
function uninstall( $package, $installType, $parameters,
                      $name, $os, $filename, $subdirectory,
                      $content, &$installParameters,
                      &$installData )
    {
        $extensionName = $content->getAttribute( 'name' );

        $siteINI = eZINI::instance();
        $extensionDir = $siteINI->variable( 'ExtensionSettings', 'ExtensionDirectory' ) . '/' . $extensionName;

        // TODO: don't delete modified files?

        if ( file_exists( $extensionDir ) )
            eZDir::recursiveDelete( $extensionDir );

        // Deactivate extension
        $siteINI = eZINI::instance( 'site.ini', 'settings/override', null, null, false, true );
        $selectedExtensions = $siteINI->variable( 'ExtensionSettings', "ActiveExtensions" );

        if ( in_array( $extensionName, $selectedExtensions ) )
        {
            $extensionsFlipped = array_flip( $selectedExtensions );

            $extKey = $extensionsFlipped[$extensionName];
            unset( $selectedExtensions[$extKey] );

            $siteINI->setVariable( "ExtensionSettings", "ActiveExtensions", $selectedExtensions );
            $siteINI->save( 'site.ini.append', '.php', false, false );
        }

        // Regenerate the autoloads to remove of no longer existing classes
        ezpAutoloader::updateExtensionAutoloadArray();

        return true;
    }
1167212
def _validate_extension(self):
        
        extension = self.fpath.split('.')[-1]
        if extension not in self.supported_extensions:
            raise UnsupportedExtensionError
351765
protected void removeCachedExtensionVersion(String feature, E extension)
    {
        // versions
        List<E> extensionVersions = this.extensionsVersions.get(feature);
        extensionVersions.remove(extension);
        if (extensionVersions.isEmpty()) {
            this.extensionsVersions.remove(feature);
        }
    }
525007
def check_name_not_on_dapi(cls, dap):
        ''''''
        problems = list()

        if dap.meta['package_name']:
            from . import dapicli
            d = dapicli.metadap(dap.meta['package_name'])
            if d:
                problems.append(DapProblem('This dap name is already registered on Dapi',
                                           level=logging.WARNING))
        return problems
1123130
public function uninstall()
    {
        $this->assertIsDebugMode();
	    try {
	        $uninstaller = new \tao_install_ExtensionUninstaller($this->getCurrentExtension());
	        $success = $uninstaller->uninstall();
	        $message = __('Uninstalled %s', $this->getRequestParameter('id'));
	    } catch (\common_Exception $e) {
	        $success = false;
	        if ($e instanceof \common_exception_UserReadableException) {
	            $message = $e->getUserMessage();
	        } else {
	            $message = __('Uninstall of %s failed', $this->getRequestParameter('id'));
	        }
	    }
        $this->returnJson(array(
	        'success' => $success,
	        'message' => $message
	    ));
	}
360618
def cleanup():
        """"""
        for install_dir in linters.INSTALL_DIRS:
            try:
                shutil.rmtree(install_dir, ignore_errors=True)
            except Exception:
                print(
                    "{0}\nFailed to delete {1}".format(
                        traceback.format_exc(), install_dir
                    )
                )
                sys.stdout.flush()
252655
def _cleanup(self):
        """"""
        self._expkg = None
        self._extmp = None
        self._flag_e = True
        self._ifile.close()
116506
def uninstall(self):
        """"""
        if self.is_installed():
            installed = self.installed_dir()
            if installed.is_symlink():
                installed.unlink()
            else:
                shutil.rmtree(str(installed))
324126
def removed(name):
    '''
    
    '''

    ret = {'name': name,
           'changes': {},
           'pchanges': {},
           'result': None,
           'comment': ''}

    old = __salt__['snap.versions_installed'](name)
    if not old:
        ret['comment'] = 'Package {0} is not installed'.format(name)
        ret['result'] = True
        return ret

    if __opts__['test']:
        ret['comment'] = 'Package {0} would have been removed'.format(name)
        ret['result'] = None
        ret['pchanges']['old'] = old[0]['version']
        ret['pchanges']['new'] = None
        return ret

    remove = __salt__['snap.remove'](name)
    ret['comment'] = 'Package {0} removed'.format(name)
    ret['result'] = True
    ret['changes']['old'] = old[0]['version']
    ret['changes']['new'] = None
    return ret
1183855
def unregister(self, entry_point):
        
        if entry_point not in self.registered_extensions:
            raise ValueError('Extension not registered')

        ep = EntryPoint.parse(entry_point)
        self.registered_extensions.remove(entry_point)
        if self._extensions_by_name is not None:
            del self._extensions_by_name[ep.name]
        for i, ext in enumerate(self.extensions):
            if ext.name == ep.name:
                del self.extensions[i]
                break
31094
def is_installed(name):
    
    pkgs = installed_packages()
    for pkge in pkgs:
        if pkge.name == name:
            return True
    return False
18186
def pip_remove(self, name=None, prefix=None, pkgs=None):
        """"""
        logger.debug(str((prefix, pkgs)))

        if isinstance(pkgs, (list, tuple)):
            pkg = ' '.join(pkgs)
        else:
            pkg = pkgs

        extra_args = ['uninstall', '--yes', pkg]

        return self._call_pip(name=name, prefix=prefix, extra_args=extra_args)
1061898
def uninstall_plugin(pkgpath, force):
    
    pkgname = os.path.basename(pkgpath)
    if os.path.exists(pkgpath):
        if not force:
            click.confirm("[?] Are you sure you want to delete `{}` from honeycomb?".format(pkgname),
                          abort=True)
        try:
            shutil.rmtree(pkgpath)
            logger.debug("successfully uninstalled {}".format(pkgname))
            click.secho("[*] Uninstalled {}".format(pkgname))
        except OSError as exc:
            logger.exception(str(exc))
    else:
        click.secho("[-] doh! I cannot seem to find `{}`, are you sure it's installed?".format(pkgname))
975386
def unsuspendTabProviders(installation):
    
    if not installation.suspended:
        raise RuntimeError("Installation not suspended")
    powerups = list(installation.allPowerups)
    allSNEs = list(powerups[0].store.powerupsFor(ISuspender))
    for p in powerups:
        for sne in allSNEs:
            if sne.originalNE is p:
                p.store.powerDown(sne, INavigableElement)
                p.store.powerDown(sne, ISuspender)
                p.store.powerUp(p, INavigableElement)
                sne.deleteFromStore()
    installation.suspended = False
795862
def uninstall(cls):
        """"""
        if os.path.exists(cls.home):
            shutil.rmtree(cls.home)
1248268
protected function uninstallExtension()
    {
        $extensionEntity = $this->getExtensionEntity();

        $this->executeAction(ExtensionManager::UNINSTALL, array(
                'id' => $extensionEntity->get('id'),
                'skipSystemRebuild' => true,
                'skipAfterScript' => true,
            )
        );
    }