syntext 1.3.0

Hybrid code search index for agent workflows
Documentation
//! Main entrypoint for syntext.
//!
//! Exposes a command-line interface to index and search code.

#[cfg(all(not(target_arch = "wasm32"), not(windows), feature = "cli"))]
fn main() {
    let code = syntext::cli::run();
    std::process::exit(code);
}

#[cfg(all(not(target_arch = "wasm32"), windows, feature = "cli"))]
fn main() {
    // clap's generated parser for the rg-compatible CLI can exceed the default
    // Windows main-thread stack. Run the actual CLI on a modestly larger stack.
    let handle = std::thread::Builder::new()
        .stack_size(8 * 1024 * 1024)
        .spawn(syntext::cli::run)
        .expect("spawn CLI thread");
    let code = match handle.join() {
        Ok(code) => code,
        Err(payload) => std::panic::resume_unwind(payload),
    };
    std::process::exit(code);
}

#[cfg(any(target_arch = "wasm32", not(feature = "cli")))]
fn main() {}