grug-far.nvim is a Neovim plugin providing an interactive find-and-replace workflow using ripgrep and ast-grep as search backends. It presents a dedicated buffer with editable input fields (search pattern, replacement, files filter, flags, paths) and renders results with highlighting, folding, and line-level diff markers. The plugin supports multiple search engines and replacement interpreters (Lua, Vimscript), history persistence, preview, quickfix integration, and instance-level API for programmatic control. The architecture is modular: an engine abstraction layer, async job processing with libuv, a rendering system using Neovim extmarks, and a task lifecycle manager. It includes a comprehensive screenshot-based test suite and CI workflows. The codebase demonstrates strong software craftsmanship with clean abstractions, reusable patterns, and extensive documentation.
fastmod is a high-performance CLI tool for large-scale codebase refactoring, designed as a faster replacement for the original codemod. It recursively searches files in a directory tree using the `ignore` and `grep` crates (the same underlying libraries as ripgrep), applies regex-based substitutions, and presents diffs for interactive review or accepts all changes automatically. The tool supports multiline regex, glob/extension filtering, case-insensitive matching, fixed-string mode, external diff tools, and hidden/ignored file traversal. The architecture is a single Rust binary with two source files: `main.rs` containing all core logic (argument parsing, file walking, patching, and interactive prompts) and `terminal.rs` wrapping `crossterm` for terminal color and clearing. Execution can be either interactive (user reviews each diff) or fast (batch apply with optional `--accept-all`). The code is well-structured, leverages parallelism via `ignore::WalkParallel`, and includes a suite of integration tests. It does not expose a library API; all functionality is encapsulated in the binary.
Ruplacer is a command-line tool written in Rust for finding and replacing text in files. It supports literal string, regex, and case-preserving replacements, and provides a diff-like output of changes. The tool respects .gitignore, allows filtering by file type, and can operate in a dry-run mode. The architecture is modular, with separate modules for argument parsing, console output, directory traversal, file processing, and the core replacement logic. The replacement logic is particularly notable for its use of the strategy pattern to handle different matching algorithms in a uniform way.