2019-06-12 19:29:56 +00:00
|
|
|
# rga - ripgrep, but also search in PDFs, E-Books, Office documents, zip, tar.gz, etc
|
|
|
|
|
2019-06-12 19:55:42 +00:00
|
|
|
[![Linux build status](https://travis-ci.org/phiresky/ripgrep_all.svg)](https://travis-ci.org/BurntSushi/ripgrep)
|
2019-06-12 20:06:21 +00:00
|
|
|
[![Crates.io](https://img.shields.io/crates/v/ripgrep_all.svg)](https://crates.io/crates/ripgrep_all)
|
2019-06-12 19:55:42 +00:00
|
|
|
|
2019-06-06 15:59:15 +00:00
|
|
|
similar:
|
|
|
|
|
2019-06-11 18:35:20 +00:00
|
|
|
- pdfgrep
|
|
|
|
- https://gist.github.com/ColonolBuendia/314826e37ec35c616d70506c38dc65aa
|
2019-06-06 15:59:15 +00:00
|
|
|
|
2019-06-06 21:19:59 +00:00
|
|
|
# todo
|
|
|
|
|
2019-06-11 18:35:20 +00:00
|
|
|
- jpg adapter (based on object classification / detection (yolo?)) for fun
|
|
|
|
- 7z adapter (couldn't find a nice to use rust library)
|
2019-06-06 21:19:59 +00:00
|
|
|
|
2019-06-06 15:59:15 +00:00
|
|
|
# considerations
|
|
|
|
|
2019-06-11 18:35:20 +00:00
|
|
|
- matching on mime (magic bytes) instead of filename
|
|
|
|
- allow per-adapter configuration options
|
2019-06-07 19:46:03 +00:00
|
|
|
|
2019-06-12 19:37:15 +00:00
|
|
|
# Setup
|
|
|
|
|
2019-06-12 19:55:42 +00:00
|
|
|
rga should compile with stable Rust. To install it, simply run
|
|
|
|
|
|
|
|
```bash
|
2019-06-12 20:03:06 +00:00
|
|
|
apt install build-essential pandoc poppler-utils sqlite3
|
2019-06-12 19:55:42 +00:00
|
|
|
cargo install ripgrep_all
|
|
|
|
|
|
|
|
rga --help
|
|
|
|
```
|
|
|
|
|
2019-06-12 19:37:15 +00:00
|
|
|
Some rga adapters run external binaries
|
|
|
|
|
2019-06-07 19:46:03 +00:00
|
|
|
# Development
|
|
|
|
|
|
|
|
To enable debug logging:
|
|
|
|
|
2019-06-07 21:04:18 +00:00
|
|
|
```bash
|
2019-06-12 15:23:30 +00:00
|
|
|
export RUST_LOG=debug
|
2019-06-07 19:46:03 +00:00
|
|
|
export RUST_BACKTRACE=1
|
2019-06-07 21:04:18 +00:00
|
|
|
```
|
2019-06-11 18:35:20 +00:00
|
|
|
|
|
|
|
Also rember to disable caching with `--rga-no-cache` or clear the cache in `~/.cache/rga` to debug the adapters.
|