guide to command

This commit is contained in:
Amber
2024-02-05 14:03:44 +01:00
parent f16897721f
commit 3a1d340f2d
2 changed files with 33 additions and 13 deletions

View File

@ -29,8 +29,6 @@ class NerdTreeFind(NerdTree):
return all([test_match, test_type])
def find_node_recursively(self, node):
# if node['name'] == self.item_name:
# if self.re_item_name.match(node['name']):
if self.found_true_cond(node):
node_copy = node.copy()
node_copy.update({'color_formatter' : YELLOW, 'found' : 1})
@ -42,8 +40,6 @@ class NerdTreeFind(NerdTree):
if item_child['type'] == 'd':
self.find_node_recursively(item_child)
else:
# if item_child['name'] == self.item_name:
# if self.re_item_name.match(item_child['name']):
if self.found_true_cond(item_child):
item_child_copy = item_child.copy()
item_child_copy.update({'color_formatter' : YELLOW, 'found' : 1})
@ -77,6 +73,7 @@ class NerdTreeFind(NerdTree):
def find_tree_struct(self):
'''
recreates the tree with search results
'''
results = self.find_node()
@ -85,11 +82,6 @@ class NerdTreeFind(NerdTree):
if not results:
return {}
# if dont_show_children_nodes:
# for result in results:
# children = result.get('children') or []
# result['nchildren'] = len(children)
# result['children'] = []
dont_show_children_nodes = self.find_opts['dont_show_children_nodes'] if self.find_opts.get('dont_show_children_nodes') is not None else False
self.opts['dont_show_children_nodes'] = dont_show_children_nodes