Remove corpus

    :param string name: corpus name
    :return: True or False
519240
def remove(name: str) -> bool:
    
    db = TinyDB(corpus_db_path())
    temp = Query()
    data = db.search(temp.name == name)

    if len(data) > 0:
        path = get_corpus_path(name)
        os.remove(path)
        db.remove(temp.name == name)
        return True

    return False
1190772
def _remove_prefix(name):
    """"""
    if isinstance(name, str):
        return _do_remove_prefix(name)
    return [_do_remove_prefix(nm) for nm in name]
738974
def RemoveKeywordsForName(self, name, keywords):
    
    data_store.DB.IndexRemoveKeywordsForName(self.urn, name, keywords)
744819
public void removeFile(String name) {
        if(files.containsKey(name)) {
            files.remove(name);
        }

        if(fileStreams.containsKey(name)) {
            fileStreams.remove(name);
        }
    }
86674
public boolean close(String name) {
		T geoPackage = remove(name);
		if (geoPackage != null) {
			close(geoPackage);
		}
		return geoPackage != null;
	}
719137
def should_be_excluded(name, exclude_patterns):
    
    for pattern in exclude_patterns:
        if fnmatch.fnmatch(name, pattern):
            return True
    return False
882891
def del_preset(self, name):
        
        policy = self.policy
        if not policy.find_preset(name):
            self.ui_log.error("Preset '%s' not found" % name)
            return False

        try:
            policy.del_preset(name=name)
        except Exception as e:
            self.ui_log.error(str(e) + "\n")
            return False

        self.ui_log.info("Deleted preset '%s'\n" % name)
        return True
737641
def _should_remove(self, i, name):
        
        if self.params[i].showkey:
            following = self.params[i + 1:]
            better_matches = [after.name.strip() == name and not after.showkey
                              for after in following]
            return any(better_matches)
        return False
328490
def remove_argument(self, name):
        
        for index, arg in enumerate(self.args[:]):
            if name == arg.name:
                del self.args[index]
                break
        return self
168274
def unregister_action(self, name):
        

        name = self.__normalize_name(name)
        action = self.get_action(name)
        if not action:
            return False

        action.triggered.disconnect(self.__actions_signals_slots.pop(action))

        category = foundations.namespace.get_namespace(name)
        name = foundations.namespace.remove_namespace(name)
        self.remove_from_category(category, name)
        return True
1094469
def remove_field(self, name):
        
        field = self.get_field(name)
        if field:
            predicat = lambda field: field.get('name') != name
            self.__current_descriptor['fields'] = filter(
                predicat, self.__current_descriptor['fields'])
            self.__build()
        return field
475156
def unregister(self, name):
        
        try:
            name = name.name
        except AttributeError:
            pass
        return self.pop(name,None)
908418
def remove(self, filename):
        
        output = self.shell('rm', filename)
        # any output means rm failed.
        return False if output else True
878124
public function removeRouteByName(string $name) : bool
    {
        if ($route = $this->getRouteByName($name)) {
            unset($this->routes[$route->getIdentifier()]);

            return true;
        }

        return false;
    }
1179189
def remove_object(self, name):
        
        if name not in self._object_map:
            raise RuntimeError('No object with name {} is registered.'.format(name))

        for fn_name in list(self._function_map.keys()):
            if fn_name.startswith(name + '.') or fn_name.startswith(name + ':'):
                self._remove_function(fn_name)

        del self._object_map[name]
675966
def remove(args):
    
    session = c.Session(args)
    if not args["name"] in session.feeds:
        sys.exit("You don't have a feed with that name.")
    inputtext = ("Are you sure you want to remove the {} "
                 " feed? (y/N) ").format(args["name"])
    reply = input(inputtext)
    if reply != "y" and reply != "Y":
        return 0
    else:
        session.feeds.remove_section(args["name"])
        with open(session.data_filename, 'w') as configfile:
            session.feeds.write(configfile)
        try:
            os.remove(os.path.join(session.data_dir, args["name"]))
        except FileNotFoundError:
            pass
462764
def remove(self, name):
        ''' 

        '''
        try:
            del self.data[name]
        except (ValueError, KeyError):
            import warnings
            warnings.warn("Unable to find column '%s' in data source" % name)