fmthoma / fmthoma/vgrep

Make `grep` tool configurable

Open
#34 0 comments 0 reactions 0 assignees View on GitHub
discussion enhancement
Dominant language
Haskell
Stars
109
Forks
8
PR merge metrics
No merged PRs in 30d

Description

E.g. in `~/.vgrep/config.yaml`:
```yaml

backend:
grep-command: "grep -nH --color=always"
recursive-grep-command: "grep -rnHI --color=always"

```

Use cases:
* People who want to use `ack`/`ag` instead of `grep`
* Passing custom options (like `-i`) by default

OTOH:
Part of the functionality can simply be emulated using a shell alias:
```
alias vgrep='function __ack_vgrep() { ack --color "$@" | vgrep; }; __ack_vgrep'
```
with the restriction that some arguments (like `--help`, `--version`) will produce garbled output, and that piping (`vgrep foo | vgrep bar`) is not possible.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.