Port glob, glob_util, and fs_cache modules from Oh My Pi's pi-natives crate, adapted for napi-rs v2. Provides gitignore-respecting filesystem discovery with a TTL-based scan cache, mtime sorting, file-type filtering, and node_modules exclusion. Includes a task module for async N-API work scheduling with cooperative cancellation (timeout-based), TypeScript type declarations and wrapper, and 12 integration tests covering pattern matching, recursion, gitignore, maxResults, sortByMtime, fileType filtering, and cache invalidation. Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
25 lines
530 B
TOML
25 lines
530 B
TOML
[package]
|
|
name = "gsd-engine"
|
|
version.workspace = true
|
|
edition.workspace = true
|
|
license.workspace = true
|
|
authors.workspace = true
|
|
repository.workspace = true
|
|
description = "N-API native addon for GSD — exposes high-performance Rust modules to Node.js"
|
|
|
|
[lib]
|
|
crate-type = ["cdylib"]
|
|
|
|
[dependencies]
|
|
gsd-grep = { path = "../grep" }
|
|
dashmap = "6"
|
|
globset = "0.4"
|
|
ignore = "0.4"
|
|
napi = { version = "2", features = ["napi8"] }
|
|
napi-derive = "2"
|
|
|
|
[build-dependencies]
|
|
napi-build = "2"
|
|
|
|
[target.'cfg(unix)'.dependencies]
|
|
libc = "0.2"
|