pi-prefer-rg
A pi extension that teaches the agent to prefer ripgrep over grep.
Package details
Install pi-prefer-rg from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:pi-prefer-rg- Package
pi-prefer-rg- Version
0.1.0- Published
- Apr 22, 2026
- Downloads
- 118/mo · 118/wk
- Author
- hdkiller
- License
- MIT
- Types
- extension
- Size
- 5.5 KB
- Dependencies
- 0 dependencies · 1 peer
Pi manifest JSON
{
"extensions": [
"./extensions"
]
}Security note
Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.
README
pi-prefer-rg
A pi extension that teaches the agent to prefer rg/ripgrep over grep in shell commands and examples.
Features
- Appends a system prompt rule to prefer
rgovergrep - Optional bash enforcement that blocks plain
grepsearch commands - Session-persistent settings via
/prefer-rg
Install
From GitHub
pi install git:github.com/hdkiller/pi-prefer-rg
From local path
pi install ./pi-prefer-rg
Usage
Reload pi after installing:
/reload
Commands:
/prefer-rg status/prefer-rg on/prefer-rg off/prefer-rg enforce-on/prefer-rg enforce-off
What it injects
The extension adds this guidance to the prompt:
- prefer
rgovergrep - use
rgby default for recursive text and code search - only use
grepif the user explicitly asks for it or grep-specific behavior is required
Development
Run pi with the local package:
pi -e ./pi-prefer-rg