Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

picker score should take all words into account #7645

Closed
doy opened this issue Jul 16, 2023 · 3 comments · Fixed by #7814
Closed

picker score should take all words into account #7645

doy opened this issue Jul 16, 2023 · 3 comments · Fixed by #7814
Assignees
Labels
C-bug Category: This is a bug

Comments

@doy
Copy link
Contributor

doy commented Jul 16, 2023

Summary

this is the result of using space-f and searching for panic attr in the rust source tree:
helix
note that it finds the whole word panic, but then the characters of attr are scattered across the results even though a file named tests/ui/test-attrs/test-should-panic-attr.rs exists - i would expect this to be the first result, but it is not even visible on the first page of results. this issue regularly makes finding files in larger repos difficult for me, because i don't even know what i could search for to give me the result i want.

i also filed this as an issue on the skim repo (lotabout/skim#526) but skim seems largely unmaintained these days, and i don't even use skim the binary, just the library implementation via helix, so it seemed worth bringing up here too.

Reproduction Steps

(see summary)

Helix log

~/.cache/helix/helix.log
2023-07-16T04:04:56.168 helix_view::clipboard [DEBUG] Using xclip to interact with the system and selection (primary) clipboard
2023-07-16T04:04:56.169 helix_tui::backend::crossterm [DEBUG] The keyboard enhancement protocol is not supported in this terminal (checked in 133.395µs)
2023-07-16T04:04:56.169 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:04:56.569 helix_term::application [DEBUG] received editor event: IdleTimer
2023-07-16T04:04:59.214 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:04:59.307 globset [DEBUG] glob converted to regex: Glob { glob: "*.{zip,gz,bz2,zst,lzo,sz,tgz,tbz2,lz,lz4,lzma,lzo,z,Z,xz,7z,rar,cab}", re: "(?-u)^[^/]*\\.(cab|rar|7z|xz|Z|z|lzo|lzma|lz4|lz|tbz2|tgz|sz|lzo|zst|bz2|gz|zip)$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([ZeroOrMore, Literal('.'), Alternates([Tokens([Literal('c'), Literal('a'), Literal('b')]), Tokens([Literal('r'), Literal('a'), Literal('r')]), Tokens([Literal('7'), Literal('z')]), Tokens([Literal('x'), Literal('z')]), Tokens([Literal('Z')]), Tokens([Literal('z')]), Tokens([Literal('l'), Literal('z'), Literal('o')]), Tokens([Literal('l'), Literal('z'), Literal('m'), Literal('a')]), Tokens([Literal('l'), Literal('z'), Literal('4')]), Tokens([Literal('l'), Literal('z')]), Tokens([Literal('t'), Literal('b'), Literal('z'), Literal('2')]), Tokens([Literal('t'), Literal('g'), Literal('z')]), Tokens([Literal('s'), Literal('z')]), Tokens([Literal('l'), Literal('z'), Literal('o')]), Tokens([Literal('z'), Literal('s'), Literal('t')]), Tokens([Literal('b'), Literal('z'), Literal('2')]), Tokens([Literal('g'), Literal('z')]), Tokens([Literal('z'), Literal('i'), Literal('p')])])]) }
2023-07-16T04:04:59.307 globset [DEBUG] built glob set; 0 literals, 0 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 1 regexes
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/.*.sw?", re: "(?-u)^(?:/?|.*/)\\.[^/]*\\.sw[^/]$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('.'), ZeroOrMore, Literal('.'), Literal('s'), Literal('w'), Any]) }
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/.~lock.*", re: "(?-u)^(?:/?|.*/)\\.\\~lock\\.[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('.'), Literal('~'), Literal('l'), Literal('o'), Literal('c'), Literal('k'), Literal('.'), ZeroOrMore]) }
2023-07-16T04:04:59.308 globset [DEBUG] built glob set; 0 literals, 4 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 2 regexes
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/*~", re: "(?-u)^(?:/?|.*/)[^/]*\\~$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, ZeroOrMore, Literal('~')]) }
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/#*", re: "(?-u)^(?:/?|.*/)\\#[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('#'), ZeroOrMore]) }
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/#*\\#", re: "(?-u)^(?:/?|.*/)\\#[^/]*\\#$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('#'), ZeroOrMore, Literal('#')]) }
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/.#*", re: "(?-u)^(?:/?|.*/)\\.\\#[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('.'), Literal('#'), ZeroOrMore]) }
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/tags.*", re: "(?-u)^(?:/?|.*/)tags\\.[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('t'), Literal('a'), Literal('g'), Literal('s'), Literal('.'), ZeroOrMore]) }
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/TAGS.*", re: "(?-u)^(?:/?|.*/)TAGS\\.[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('T'), Literal('A'), Literal('G'), Literal('S'), Literal('.'), ZeroOrMore]) }
2023-07-16T04:04:59.308 globset [DEBUG] glob converted to regex: Glob { glob: "**/*.py[cod]", re: "(?-u)^(?:/?|.*/)[^/]*\\.py[cod]$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, ZeroOrMore, Literal('.'), Literal('p'), Literal('y'), Class { negated: false, ranges: [('c', 'c'), ('o', 'o'), ('d', 'd')] }]) }
2023-07-16T04:04:59.308 globset [DEBUG] built glob set; 16 literals, 22 basenames, 3 extensions, 0 prefixes, 0 suffixes, 2 required extensions, 7 regexes
2023-07-16T04:04:59.309 globset [DEBUG] built glob set; 1 literals, 1 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.310 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/library/portable-simd/.github: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.311 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/library/portable-simd/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.330 globset [DEBUG] built glob set; 0 literals, 1 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.331 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_smir/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.332 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_llvm/llvm-wrapper/.editorconfig: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.333 ignore::walk [DEBUG] whitelisting /home/doy/coding/src/rust/compiler/rustc_mir_build/src/build: Whitelist(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: "!/compiler/rustc_mir_build/src/build/", actual: "compiler/rustc_mir_build/src/build", is_whitelist: true, is_only_dir: true })))
2023-07-16T04:04:59.333 globset [DEBUG] glob converted to regex: Glob { glob: "**/*.string*", re: "(?-u)^(?:/?|.*/)[^/]*\\.string[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, ZeroOrMore, Literal('.'), Literal('s'), Literal('t'), Literal('r'), Literal('i'), Literal('n'), Literal('g'), ZeroOrMore]) }
2023-07-16T04:04:59.333 globset [DEBUG] built glob set; 11 literals, 2 basenames, 3 extensions, 0 prefixes, 0 suffixes, 1 required extensions, 1 regexes
2023-07-16T04:04:59.334 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_codegen_cranelift/.cirrus.yml: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.334 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_codegen_cranelift/.github: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.334 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_codegen_cranelift/.vscode: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: ".vscode", actual: "**/.vscode", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.335 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_codegen_cranelift/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.335 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_codegen_cranelift/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.339 globset [DEBUG] glob converted to regex: Glob { glob: "**/*.string*", re: "(?-u)^(?:/?|.*/)[^/]*\\.string[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, ZeroOrMore, Literal('.'), Literal('s'), Literal('t'), Literal('r'), Literal('i'), Literal('n'), Literal('g'), ZeroOrMore]) }
2023-07-16T04:04:59.339 globset [DEBUG] glob converted to regex: Glob { glob: "**/gimple*", re: "(?-u)^(?:/?|.*/)gimple[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('g'), Literal('i'), Literal('m'), Literal('p'), Literal('l'), Literal('e'), ZeroOrMore]) }
2023-07-16T04:04:59.339 globset [DEBUG] glob converted to regex: Glob { glob: "**/*asm", re: "(?-u)^(?:/?|.*/)[^/]*asm$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, ZeroOrMore, Literal('a'), Literal('s'), Literal('m')]) }
2023-07-16T04:04:59.339 globset [DEBUG] built glob set; 11 literals, 8 basenames, 3 extensions, 0 prefixes, 0 suffixes, 1 required extensions, 3 regexes
2023-07-16T04:04:59.339 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_codegen_gcc/.github: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.340 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_codegen_gcc/.rustfmt.toml: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.340 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/compiler/rustc_codegen_gcc/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.348 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.github: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.350 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/tests/rustdoc-gui/src/settings/.cargo: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: ".cargo", actual: "**/.cargo", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.374 ignore::walk [DEBUG] whitelisting /home/doy/coding/src/rust/tests/run-make/thumb-none-qemu/example/.cargo: Whitelist(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: "!/tests/run-make/thumb-none-qemu/example/.cargo", actual: "tests/run-make/thumb-none-qemu/example/.cargo", is_whitelist: true, is_only_dir: false })))
2023-07-16T04:04:59.379 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/tests/rustdoc-ui/intra-doc/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.421 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/tests/ui/issues/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.449 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/tests/ui/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.453 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.gitmodules: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.453 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.reuse: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.453 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.git-blame-ignore-revs: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.453 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.mailmap: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.453 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.git: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.455 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/librustdoc/html/static/.eslintrc.js: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.455 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rustdoc-gui/.eslintrc.js: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.455 globset [DEBUG] built glob set; 11 literals, 4 basenames, 9 extensions, 0 prefixes, 0 suffixes, 2 required extensions, 0 regexes
2023-07-16T04:04:59.456 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/clippy/.github: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.456 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/clippy/tests/ui-cargo/multiple_config_files/warn/.clippy.toml: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.457 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/clippy/tests/ui-cargo/multiple_crate_versions/fail/Cargo.lock: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/src/tools/clippy/.gitignore"), original: "*Cargo.lock", actual: "**/*Cargo.lock", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.465 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/clippy/.cargo: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: ".cargo", actual: "**/.cargo", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.467 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/clippy/.remarkrc: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.467 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/clippy/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.467 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/clippy/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.467 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/clippy/.editorconfig: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.467 globset [DEBUG] glob converted to regex: Glob { glob: "**/*~", re: "(?-u)^(?:/?|.*/)[^/]*\\~$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, ZeroOrMore, Literal('~')]) }
2023-07-16T04:04:59.467 globset [DEBUG] built glob set; 0 literals, 3 basenames, 0 extensions, 0 prefixes, 0 suffixes, 1 required extensions, 1 regexes
2023-07-16T04:04:59.468 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-installer/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.468 globset [DEBUG] glob converted to regex: Glob { glob: "tests/cargo-fmt/**/target", re: "(?-u)^tests/cargo\\-fmt(?:/|/.*/)target$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([Literal('t'), Literal('e'), Literal('s'), Literal('t'), Literal('s'), Literal('/'), Literal('c'), Literal('a'), Literal('r'), Literal('g'), Literal('o'), Literal('-'), Literal('f'), Literal('m'), Literal('t'), RecursiveZeroOrMore, Literal('t'), Literal('a'), Literal('r'), Literal('g'), Literal('e'), Literal('t')]) }
2023-07-16T04:04:59.468 globset [DEBUG] glob converted to regex: Glob { glob: "**/*~", re: "(?-u)^(?:/?|.*/)[^/]*\\~$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, ZeroOrMore, Literal('~')]) }
2023-07-16T04:04:59.468 globset [DEBUG] built glob set; 1 literals, 3 basenames, 0 extensions, 0 prefixes, 0 suffixes, 1 required extensions, 2 regexes
2023-07-16T04:04:59.468 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rustfmt/.github: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rustfmt/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rustfmt/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 globset [DEBUG] built glob set; 0 literals, 1 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rustfmt/config_proc_macro/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rustfmt/.editorconfig: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 globset [DEBUG] glob converted to regex: Glob { glob: "crates/*/target", re: "(?-u)^crates/[^/]*/target$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([Literal('c'), Literal('r'), Literal('a'), Literal('t'), Literal('e'), Literal('s'), Literal('/'), ZeroOrMore, Literal('/'), Literal('t'), Literal('a'), Literal('r'), Literal('g'), Literal('e'), Literal('t')]) }
2023-07-16T04:04:59.478 globset [DEBUG] glob converted to regex: Glob { glob: ".idea/*", re: "(?-u)^\\.idea/[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([Literal('.'), Literal('i'), Literal('d'), Literal('e'), Literal('a'), Literal('/'), ZeroOrMore]) }
2023-07-16T04:04:59.478 globset [DEBUG] built glob set; 5 literals, 5 basenames, 2 extensions, 0 prefixes, 0 suffixes, 2 required extensions, 2 regexes
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/.github: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/.vscode: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: ".vscode", actual: "**/.vscode", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/.cargo: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: ".cargo", actual: "**/.cargo", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.478 globset [DEBUG] built glob set; 0 literals, 6 basenames, 1 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/editors/code/.vscodeignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/editors/code/package-lock.json: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: "package-lock.json", actual: "**/package-lock.json", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/editors/code/package.json: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: "package.json", actual: "**/package.json", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/editors/code/.prettierignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/editors/code/.eslintrc.js: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.478 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/editors/code/.eslintignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.479 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/editors/code/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.479 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/editors/code/.prettierrc.js: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.479 globset [DEBUG] built glob set; 0 literals, 1 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.479 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/docs/user/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.479 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/crates/ide/src/syntax_highlighting/tags.rs: Ignore(IgnoreMatch(Gitignore(Glob { from: Some("/home/doy/coding/src/rust/.gitignore"), original: "tags.*", actual: "**/tags.*", is_whitelist: false, is_only_dir: false })))
2023-07-16T04:04:59.483 globset [DEBUG] built glob set; 0 literals, 4 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.483 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/crates/syntax/fuzz/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.486 globset [DEBUG] built glob set; 0 literals, 2 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.486 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/crates/proc-macro-test/imp/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.487 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/.git-blame-ignore-revs: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.487 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.487 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.487 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rust-analyzer/.editorconfig: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.488 globset [DEBUG] glob converted to regex: Glob { glob: "tex/*/out", re: "(?-u)^tex/[^/]*/out$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([Literal('t'), Literal('e'), Literal('x'), Literal('/'), ZeroOrMore, Literal('/'), Literal('o'), Literal('u'), Literal('t')]) }
2023-07-16T04:04:59.488 globset [DEBUG] glob converted to regex: Glob { glob: "**/.auto-*", re: "(?-u)^(?:/?|.*/)\\.auto\\-[^/]*$", opts: GlobOptions { case_insensitive: false, literal_separator: true, backslash_escape: true }, tokens: Tokens([RecursivePrefix, Literal('.'), Literal('a'), Literal('u'), Literal('t'), Literal('o'), Literal('-'), ZeroOrMore]) }
2023-07-16T04:04:59.488 globset [DEBUG] built glob set; 2 literals, 5 basenames, 3 extensions, 0 prefixes, 0 suffixes, 1 required extensions, 2 regexes
2023-07-16T04:04:59.488 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/miri/.github: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.493 globset [DEBUG] built glob set; 0 literals, 3 basenames, 1 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.493 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/miri/test-cargo-miri/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.494 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/miri/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.494 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/miri/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.494 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/miri/.editorconfig: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.494 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/miri/.gitpod.yml: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.494 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/tools/rustdoc-js/.eslintrc.js: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.494 globset [DEBUG] built glob set; 0 literals, 1 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.495 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/doc/unstable-book/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.495 globset [DEBUG] built glob set; 0 literals, 1 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.495 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/doc/rustdoc/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.495 globset [DEBUG] built glob set; 0 literals, 1 basenames, 0 extensions, 0 prefixes, 0 suffixes, 0 required extensions, 0 regexes
2023-07-16T04:04:59.495 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/src/doc/rustc/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.495 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.gitattributes: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.495 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.gitignore: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.495 ignore::walk [DEBUG] ignoring /home/doy/coding/src/rust/.editorconfig: Ignore(IgnoreMatch(Hidden))
2023-07-16T04:04:59.568 helix_term::ui [DEBUG] file_picker init 262.979717ms
2023-07-16T04:04:59.603 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:04:59.707 helix_term::application [DEBUG] received editor event: IdleTimer
2023-07-16T04:04:59.707 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:00.372 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:00.427 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:00.561 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:00.684 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:00.817 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:00.985 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:01.148 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:01.334 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:01.498 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:01.657 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0
2023-07-16T04:05:02.035 helix_term::application [DEBUG] received editor event: IdleTimer
2023-07-16T04:05:02.035 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0

Platform

linux

Terminal Emulator

alacritty 0.12.2

Helix Version

helix 23.05

@doy doy added the C-bug Category: This is a bug label Jul 16, 2023
@pascalkuthe
Copy link
Member

Like in other fuzzy matchers (fzf, skim) helix treat words sperate by a space as and so foo bar matches too and bar seperatly (so they can overlap). If you actually want to match a whitespace then you need to escape it foo\ bar

@pascalkuthe pascalkuthe closed this as not planned Won't fix, can't repro, duplicate, stale Jul 16, 2023
@doy
Copy link
Contributor Author

doy commented Jul 16, 2023

no, this isn't what i'm referring to at all - i don't want it to match literal spaces. if you look at the results that fzf returns:
fzf
it still prefers matches where the letters in attr are next to each other, which is much more useful behavior. helix will prefer matches where the letters are next to each other for the first word that it matches, but it doesn't do that for subsequent words, making it extremely hard to search for files in large repositories where there might be a lot of different matches for a single word.

@pascalkuthe
Copy link
Member

Ah I missunderstood then. Each word gets its own fuzzy match score and we simply sort by the first one. I think we can probably improve on that by summing scores. The current behavior matches skim but fzf does seem to do better here

@pascalkuthe pascalkuthe reopened this Jul 16, 2023
@pascalkuthe pascalkuthe changed the title fuzzy matching works poorly on words past the first picker score should take all words into account Jul 16, 2023
@pascalkuthe pascalkuthe self-assigned this Aug 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug
Projects
None yet
2 participants