@firstpick/pi-extension-safety-guard

Interactive guardrails for dangerous bash commands and protected file edits in Pi.

Package details

extension

Install @firstpick/pi-extension-safety-guard from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:@firstpick/pi-extension-safety-guard
Package
@firstpick/pi-extension-safety-guard
Version
0.1.1
Published
May 3, 2026
Downloads
not available
Author
firstpick
License
MIT
Types
extension
Size
5 KB
Dependencies
0 dependencies · 1 peer
Pi manifest JSON
{
  "extensions": [
    "./index.ts"
  ]
}

Security note

Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.

README

pi-extension-safety-guard

Interactive safety prompts for high-risk operations in Pi.

What it does

  • Intercepts dangerous bash commands and requires confirmation.
  • Intercepts write/edit on protected paths and requires confirmation.
  • In non-interactive mode, blocks risky operations with explicit reasons.

Default dangerous command patterns include:

  • rm -rf, sudo, mkfs, dd
  • shutdown, reboot, poweroff
  • common fork-bomb signature

Default protected-path patterns include:

  • .ssh, .git-credentials, auth.json
  • id_rsa, id_ed25519 (and .pub)
  • .env and .env.*

Install

pi install npm:@firstpick/pi-extension-safety-guard

Configuration

No required configuration.

Commands

None.

Tools

None.