Install
Install with PiG
pig install npm:pi-readonly-modeInstall with Pi
pi install npm:pi-readonly-modeReview before installing
Packages run code with your permissions and influence agent behavior. Catalog inclusion is not a security audit. Review the source before installing a third-party package.
Pi manifest JSON
The pi field of package.json.
{
"extensions": [
"./extensions/readonly-mode.ts"
]
}README
Written by the package's publisher, shown as published in version 1.0.0 (README.md). PiG does not review it.
pi-readonly-mode
Strict read-only mode extension for pi.
While active it:
- Limits the active tool set to
read,bash,grep,find,ls,question. - Silently blocks
editandwritetool calls. - Blocks
bashcommands matching destructive patterns (rm,mv,cp,sudo, git writes, package installs, redirects, editors, etc.). - Injects hidden guidance telling the model it may only inspect and analyze.
- Shows a small
READONLYstatus indicator. - Persists across sessions and resumes.
Install
pi install npm:pi-readonly-mode
Or try it for a single invocation without saving it:
pi -e npm:pi-readonly-mode
Use
- Toggle during a session with
/readonly. - Start a session read-only with
pi --readonly.
The mode is persisted in the session, so resuming a session restores its state.
License
MIT