A pi extension that opens files in your preferred editor from within pi.
pi install npm:pi-editorOr try it without installing:
pi -e npm:pi-editor/edit <path> Open a file in $VISUAL or $EDITOR
The command resolves the path relative to your current working directory and spawns the editor attached to your terminal. If the file doesn't exist, you'll be prompted to create it.
The extension checks these environment variables in order:
$VISUAL— preferred for full-screen editors (e.g.nvim,code --wait)$EDITOR— fallback (e.g.vim,nano)vi— default if neither is set
MIT