mirror of
https://github.com/wting/autojump
synced 2024-10-27 20:34:07 +00:00
Fixed order of match precedence and match_anywhere example
This commit is contained in:
parent
c4d82b1888
commit
0ecf1b4e3b
@ -193,8 +193,8 @@ def find_matches(entries, needles, check_entries=True):
|
|||||||
lambda entry: not is_cwd(entry) and path_exists(entry),
|
lambda entry: not is_cwd(entry) and path_exists(entry),
|
||||||
chain(
|
chain(
|
||||||
match_consecutive(needles, data, ignore_case),
|
match_consecutive(needles, data, ignore_case),
|
||||||
match_fuzzy(needles, data, ignore_case),
|
match_anywhere(needles, data, ignore_case),
|
||||||
match_anywhere(needles, data, ignore_case)))
|
match_fuzzy(needles, data, ignore_case)))
|
||||||
|
|
||||||
|
|
||||||
def handle_tab_completion(needle, entries):
|
def handle_tab_completion(needle, entries):
|
||||||
|
@ -32,7 +32,7 @@ def match_anywhere(needles, haystack, ignore_case=False):
|
|||||||
]
|
]
|
||||||
|
|
||||||
result = [
|
result = [
|
||||||
(path='/moo/foo/baz', weight=10),
|
(path='/foo/bar/baz', weight=10),
|
||||||
(path='/foo/baz', weight=10),
|
(path='/foo/baz', weight=10),
|
||||||
]
|
]
|
||||||
"""
|
"""
|
||||||
|
Loading…
Reference in New Issue
Block a user