Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>FindItFaster: SonarNew to Visual Studio Code? Get it now.
FindItFaster: Sonar

FindItFaster: Sonar

stoffej

|
46 installs
| (0) | Free
FindItFaster fork with query filter syntax, current-file search, persisted fzf history.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

FindItFaster: Sonar

pong… pong… is da sound of the Sonar

Fork of FindItFaster. Linux + WSL. File/content search powered by fzf, rg, bat.

What's new

  • 0.1.7 — .gitignore/search.exclude filtering is now its own @ignore token, independent of @group. Removed 15 rarely-touched settings, each hardcoded to its old default so nobody's behavior changes.
  • 0.1.6 — Search everywhere by default (.gitignore ignored, hidden files included, only .git/ skipped). Filtering opt-in per query via @group tokens, !dir/ shorthand, and Tab completion. findFiles.defaultGroups for persistent groups. fzf version probing moved to activation with output-channel warnings. Faster incremental search (100 ms debounce dropped). bat defaults to Dracula theme. Filenames with : open at the correct line (ripgrep 13+).
  • 0.1.5 — Fixes TYPE_FILTER in find-within-open-files (was a no-op). README updates.
  • 0.1.4 — Filetype pickers (alt+j / alt+u), // tokens filter syntax.
  • 0.1.3 — Preflight for missing tools. WSL paste.
  • 0.1.1 — First Sonar release.

What's different from upstream

  • pattern // [type|.ext|glob|!type|!dir/|@group|@ignore] ... filter + group syntax, in Search file and Search within files
  • .gitignore and search.exclude no longer filter anything unless you ask for it (@ignore)
  • New commands: search within current file, search within open files
  • Query history persisted across sessions (~/.cache/find-it-faster/history)
  • ctrl+x clears, ctrl+v pastes (wl-paste / xclip / powershell.exe)
  • Linux only (WSL supported); macOS / native Windows removed
  • Settings prefix is fif-sonar.* — see Migrating from FindItFaster

Install

sudo apt-get install -y fzf ripgrep bat && sudo ln -sf /usr/bin/batcat /usr/local/bin/bat

(Debian/Ubuntu ships bat as batcat, hence the symlink.)

Version thresholds. The only hard requirement is that fzf and rg are on PATH. Older versions still work; each threshold below only costs you the feature next to it:

Tool Version What it buys
rg 13 --field-match-separator — without it, filenames containing : open at the wrong line (Ubuntu 22.04+, Debian bookworm+; grab a .deb from ripgrep releases on older distros)
fzf 0.27 configurable preview window
fzf 0.36 cursor position restored on Resume last search
fzf 0.38 ctrl+v paste
fzf 0.45 Tab completion of @group names

At activation the extension probes fzf --version and rg --version once and exports the resulting capability flags to the scripts. Anything you're missing is listed in the FindItFaster: Sonar output channel (View → Output) with a clear ASCII border — searching still works, just degraded. Upgrade the offending tool and reload the window to clear it.

Missing fzf or rg → clear error in the terminal (doesn't auto-close). Missing bat → preview disabled, warning only.

WSL on Windows

  1. wsl --install -d Ubuntu (PowerShell)
  2. Install deps above in WSL
  3. VSCode: install Remote - WSL, reopen folder in WSL
  4. Install FindItFaster: Sonar into the WSL window

ctrl+v reads the Windows clipboard via powershell.exe.

Commands

Prefix: Sonar: in the command palette.

Command Keybinding
Search file ctrl+shift+j
Search file (with type filter) ctrl+shift+alt+j
Search within files ctrl+shift+u
Search within files (with type filter) ctrl+shift+alt+u
Search within current file —
Search within open files —
Resume last search —

The *With type filter variants pre-narrow rg via -t <type> — faster than any query-level filter on big repos.

Query syntax

Every command splits its query at //: left is the matcher, right is an optional file filter. The filter syntax is the same everywhere it is available.

Command Left of // // tokens
Search file fzf extended-search over paths yes
Search within files rg regex over content yes
Search within current file fzf extended-search no — single file
Search within open files rg regex over content no — see below

fzf extended-search syntax (Search file, Search within current file)

Standard fzf syntax — 'exact, ^prefix, suffix$, !negate, a | b for OR, space for AND. See man fzf (EXTENDED SEARCH MODE) for the full reference.

Examples:

.svg$                      # every .svg file
icons .svg$                # .svg files matching "icons" fuzzily
'exact-name                # filenames containing the literal "exact-name"
^src .ts$ | .tsx$          # TypeScript under src/
config | settings .json$   # config.json or settings.json
test !.spec.               # anything with "test" but not ".spec."

rg regex + // tokens file filter (Search file, Search within files)

Right of //, space-separated. Identical in both commands.

Token Effect rg flag
c rg type (e.g. .c/.h) -t c
!c exclude C files -T c
*.c glob -g '*.c'
!*_test.c negated glob -g '!*_test.c'
src/** top-level src/ only -g 'src/**'
!node_modules/** top-level node_modules/ only -g '!node_modules/**'
.md shorthand for *.md -g '*.md'
!vendor/ exclude vendor/ at any depth -g '!**/vendor/**'
@embedded exclude group embedded's entries -g '!…' per entry
@ignore honor .gitignore + search.exclude (built in) --ignore --no-require-git

Glob vs type: contains *?/. → glob, otherwise rg type. rg --type-list for types.

Default mode searches everything — .gitignore is NOT honored and hidden files are included (only .git/ itself is skipped). Filtering is opt-in per query, and the two kinds are independent: @group excludes that group's entries, @ignore honors .gitignore + search.exclude. Excluding build directories therefore never hides a gitignored file you deliberately search for; combine them (@embedded @ignore) when you want both. Configure groups with general.excludeDirectoryGroups, or findFiles.defaultGroups to apply them to every Search file run without typing them — see Settings. Tab completes @group names, @ignore included (fzf ≥ 0.45).

Path globs are root-anchored. src/** matches top-level src/ only — use **/src/** for nested. Same for !node_modules/**.

Not available in "Search within open files". rg applies neither --type nor --glob nor ignore rules to explicit file arguments, so // tokens cannot work there — the command says so and refuses rather than returning unfiltered results.

Examples:

todo // c                       # "todo" in C files
handler // py !*_test.py        # "handler" in Python, skip test files
foo // src/**                   # "foo" under top-level src/ (use **/src/** for nested)
config // *.json !**/dist/**    # "config" in JSON, skip dist dirs
cleanup // !vendor/             # skip vendor/ at any depth (dir shorthand)
todo // @embedded               # exclude group "embedded"; .gitignore still off
todo // @embedded @ignore       # ...and honor .gitignore + search.exclude
todo // @embedded @py c         # both groups, C sources only
^import .* from // ts           # regex on the left, file filter on the right

Empty pattern: // py matches every line of every .py file — a way to browse a filetype rather than search it.

Recipes

First word = which command to run.

Find files

Search file    .svg$                      every SVG
Search file    ^src/ .ts$ | .tsx$         TS/TSX under src/
Search file    'README                    literal "README" in name
Search file    migration !.sql$           "migration" but not .sql
Search file    !test !spec                neither test nor spec
Search file    ^docs .md$                 markdown under docs/
Search file    config | settings .json$   config.json or settings.json

Search within files

Search within files   TODO // py                   TODOs in Python
Search within files   ^def\s+\w+ // py             Python function defs
Search within files   use[A-Z]\w+ // ts            React hooks (ts covers .tsx)
Search within files   https?://\S+ // md           URLs in markdown
Search within files   TODO|FIXME|XXX // !*_test.*  todos outside tests
Search within files   FIXME // src/** !*.lock      fixmes under src/, not lockfiles
Search within files    // py                       browse every line of every .py file

Search within current file

Search within current file   .error$          lines ending in "error"
Search within current file   ^return          lines starting with `return`
Search within current file   'throw           lines with literal "throw"
Search within current file   TODO | FIXME     either tag

Fastest: rg pre-filter (large repos)

ctrl+shift+alt+j  → "svg"    # only .svg files
ctrl+shift+alt+u  → "py"     # within .py only

Tips

  • ctrl+p / ctrl+n — fzf's own history binds; the extension gives them 30 entries that survive a reload (~/.cache/find-it-faster/history)
  • ctrl+v — paste from the clipboard (needs fzf ≥ 0.38)
  • ctrl+x — clear the query
  • tab — complete/cycle @group names, @ignore included, in Search file and Search within files (needs fzf ≥ 0.45)

Everything else in the picker is stock fzf — see man fzf for the full key list.

Settings

@ext:stoffej.fif-sonar in settings. Keys under fif-sonar.*.

Migrating from FindItFaster

Keys are fif-sonar.*, not find-it-faster.*. VS Code keeps old keys silently, so they look active while their values revert to this extension's defaults. general.useGitIgnoreExcludes and general.useWorkspaceSearchExcludes are gone entirely — .gitignore and search.exclude are now opt-in per query via @ignore (or permanently for Search file via findFiles.defaultGroups: ["ignore"]).

General

Key Default Purpose
general.hideTerminalAfterSuccess true Hide terminal after pick.
general.hideTerminalAfterFail true Also hide on cancel.
general.clearTerminalAfterUse true clear before hiding.
general.killTerminalAfterUse true Dispose terminal fully.
general.showMaximizedTerminal false Maximize while picking.
general.excludeDirectoryGroups {} Named exclude groups for @group query tokens. An entry with */? is a file glob (*.o), anything else a directory name (dist). settings.json only.
general.batTheme "Dracula" Preview theme. Matches the fzf colors.

Find files

Key Default Purpose
findFiles.defaultGroups [] Groups from general.excludeDirectoryGroups applied to every Search file, plus the built-in "ignore". Empty = list everything.

defaultGroups: ["ignore"] is the persistent form of typing // @ignore: Search file then honors .gitignore + search.exclude on every run. It applies to Search file only — Search within files has // tokens, so you ask for @ignore there per query. And it stays independent of ordinary groups: ["embedded", "ignore"] excludes the embedded group's entries and follows .gitignore, while ["embedded"] alone leaves .gitignore off.

Find within files

findWithinFiles has no configurable settings — preview, its command/window layout, and query matching (always exact, no fuzzing) are fixed.

Advanced

advanced has no configurable settings — the startup preflight never runs, and the query is always seeded from the editor selection.

Example settings

Every setting, at its default unless noted (Ctrl+Shift+P → Preferences: Open User Settings (JSON)). Copy the whole block and delete what you don't care about — omitting a key is the same as leaving it at the value shown.

{
    // ---------- Exclude groups ----------
    // Each key is a @group name used in queries. A bare entry is a directory
    // name matched at any depth ("dist" -> !**/dist/**); an entry containing
    // * or ? is a file glob used as-is ("*.o" -> !*.o). A group excludes ONLY
    // its own entries — .gitignore is the separate, built-in @ignore token.
    // "ignore" is reserved and cannot be used as a group name.
    "fif-sonar.general.excludeDirectoryGroups": {
        "embedded": ["build", ".pio", "cmake-build-debug", "Debug", "Release"],
        "obj":      ["*.o", "*.hex"],
        "py":       [".venv", "__pycache__", ".mypy_cache", "*.pyc"]
    },

    // ---------- Find files ----------
    // Groups applied to every Search file run without typing them. The
    // built-in "ignore" belongs here too — it is how you make Search file
    // honor .gitignore + search.exclude permanently. Default: []
    "fif-sonar.findFiles.defaultGroups": ["embedded", "ignore"],

    // ---------- Terminal behavior ----------
    "fif-sonar.general.hideTerminalAfterSuccess": true,
    "fif-sonar.general.hideTerminalAfterFail": true,
    "fif-sonar.general.clearTerminalAfterUse": true,
    "fif-sonar.general.killTerminalAfterUse": true,
    "fif-sonar.general.showMaximizedTerminal": false,

    // ---------- Presentation ----------
    "fif-sonar.general.batTheme": "Dracula"
}

With the groups above, todo // @embedded searches for "todo" while skipping build/, .pio/, etc. — .gitignore stays off unless you add @ignore. todo // @embedded @obj c adds the object files and limits to C sources. In Search file the two entries in defaultGroups are already applied, so you only type what you want on top of them.

FAQ

Ctrl+K doesn't move up in fzf. Set "terminal.integrated.allowChords": false.

Files from other folders don't show up. Picker uses terminal cwd. Open the wider folder.

Terminal closes before I can read an error. On precondition failure the extension keeps it open. If it still disappears, a workspace override on hideTerminalAfterFail may be overriding the extension.

Preview empty. bat missing. Install it.

A file I know is .gitignored doesn't show up. Default mode ignores .gitignore — it should show up. Example, with build/output.js gitignored:

Query Shows build/output.js? Why
output yes default mode searches everything
output // @ignore no @ignore honors .gitignore
output // @web (some other group) yes @group excludes only its own entries, not gitignored files

Still missing with a plain query? ctrl+x clears the query first — Resume last search can silently bring back an old @ignore/@group from a previous search. Then verify outside the extension, from the workspace root:

rg --files --hidden --no-ignore --glob '!**/.git/' | grep -F build/output.js

No match there either → it's an rg/gitignore-pattern interaction (or the file genuinely isn't there), not this extension — that's the exact command the picker runs by default.

Native Windows? Not supported. Use WSL.

Credits

Thanks to Tom Rijndorp for FindItFaster — this fork is built on it.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft