omni

SvelteRustTauriWindows

Overview

Fast file search for Windows — native Rust-powered BFS scanning with a clean GUI. Glob, regex, filters, sort, and one-click reveal in Explorer.

Problem

Windows search (SearchIndexer) is slow, doesn't index all locations, and lacks glob/regex support. EverythingSearch requires a background daemon and database. Users want on-demand, no-indexing file search with flexible queries and instant results.

Approach

Built a Tauri 2 app with a Rust BFS engine that walks drives on demand — no indexing, no daemon, no database. Parallelized with rayon for concurrent directory traversal. Three query modes: plain substring, glob patterns, and regex. Results stream in breadth-first order so shallow files appear first.

Architecture

Rust backend (606 lines) handles all search logic: scope resolution (global/drive/folder), parallel BFS with walkdir + rayon, query matching via a Matcher enum (Substring/GlobPattern/Regex), and smart skip lists (WinSxS, AppData, node_modules, etc.). Directory caps (20k/50k) prevent runaway traversal. Svelte 5 frontend uses runes ($state, $derived, $effect) for reactive rendering with two view modes (list/tiles).

Challenges

Windows-only by design (robocopy-based reveal, explorer /select). No indexing means slower searches on very large drives — mitigated with directory caps and result limits. Symlink loop protection via canonicalize + shared HashSet. User-defined exclude patterns are compiled server-side. Directory traversal protection on reveal/open commands.

Results

A sub-5 MB desktop search tool covering all drives with glob/regex, type/date filters, sort controls, match highlighting, recent searches, and instant reveal — no daemon, no indexing, no database.

Technology

Svelte 5RustTauri 2TypeScriptrayonwalkdirregexLucide
Email copied