acheronfail/repgrep
Tentang
An interactive replacer for ripgrep that makes it easy to find and replace across files on the command line.
Alat pengembanganPertumbuhan bintang terukur
- dalam 24 jam
- +2
- dalam 7 hari
- +2
- dalam 15 hari
- +3
- dalam 1 bulan
- Mengumpulkan riwayat
Perubahan bersih pada periode yang tumpang tindih, bukan total harian. Pengukuran yang belum tersedia dibiarkan kosong. Bintang menunjukkan perhatian, bukan kualitas.
README.md
Aslirepgrep (rgr)
An interactive replacer for ripgrep.
This is an interactive command line tool to make find and replacement easy.
It uses ripgrep to find, and then provides you with a simple interface to see
the replacements in real-time and conditionally replace matches.
Some features:
- ⚡ Super fast search results
- ✨ Interactive interface for selecting which matches should be replaced or not
- 🕶️ Live preview of the replacements
- 🧠 Replace using capturing groups (e.g., when using
/foo (\w+)/replace withbar $1) - 🦀 and more!
Supported file encodings:
- ASCII
- UTF8
- UTF16BE
- UTF16LE
Other encodings are possibly supported but untested at the moment. See this issue for more information.
Usage
After installing, just use rgr (think: rg + replace).
Pass ripgrep's -r/--replace option to prefill the replacement text while retaining the
interactive match-selection and confirmation steps:
rgr 'old_name' -r 'new_name'
Use rgr's -y/--autoreplace option with -r/--replace to replace every match without
opening the interactive interface:
rgr -y 'old_name' -r 'new_name'
The arguments are:
rgr <rg arguments> # See `rgr --help` for more details
Here's an example where we ran the command:
rgr -C5 dreamcast
And have entered the replacement flycast:

Installation
First and foremost, make sure you've installed ripgrep (AKA: rg).
To do so see the ripgrep installation instructions.
Precompiled binaries
See the releases page for pre-compiled binaries.
Via Cargo
NOTE: The minimum Rust version required is 1.96.0.
cargo install repgrep
Via Pacman (Arch Linux)
repgrep can be installed
from the official repositories using Pacman.
pacman -S repgrep
Via MacPorts (macOS)
repgrep can also be installed on macOS using MacPorts:
sudo port install repgrep
More info here.
From Source
NOTE: The minimum Rust version required is 1.96.0.
git clone https://github.com/acheronfail/repgrep/
cd repgrep
cargo install --path .
License: Unlicense OR MIT OR Apache-2.0
Jelajahi proyek terkait
Memuat…