pi-env-probe
v0.1.2
Published
Cross-platform environment diagnostics for Pi — shell, PATH, runtime, encoding, non-ASCII path risks in compact JSON
Downloads
306
Maintainers
Readme
pi-env-probe
Cross-platform environment diagnostics for Pi — shell, PATH, runtime, encoding, and non-ASCII path risks in compact JSON.
What this is
pi-env-probe collects lightweight environment diagnostics and returns them as compact JSON. Use it from the CLI, as a Pi slash command, or import probe() in your own tooling.
Features
- Detects the current shell (
bash,pwsh,cmd,zsh, ornull) - Reports whether common shells are available in
PATH - Returns the platform path separator (
;on Windows,:on POSIX) - Never throws from
probe()— subprocess failures degrade tofalse/null
Install
Install the published npm package with Pi:
pi install npm:pi-env-probeInstall into the current project instead of your user Pi settings:
pi install npm:pi-env-probe -lOr install from GitHub:
pi install git:github.com/eiei114/pi-env-probeTry it without permanently installing:
pi -e npm:pi-env-probeQuick start
Try this package locally:
pi -e .Then run:
/env-probeOr use the standalone CLI:
node bin/env-probe.jsPackage contents
| Path | Purpose |
|---|---|
| lib/ | Shared probe logic (probe.ts) |
| extensions/ | Pi extension registering /env-probe |
| bin/ | Standalone CLI entry point |
Development
npm install
npm run ciVerification
npm install
npm run typecheck
npm test
node bin/env-probe.js
node bin/env-probe.js | node -e "process.stdin.on('data',d=>{JSON.parse(d);console.log('valid JSON')})"
npm pack --dry-runRelease
This package is set up for npm Trusted Publishing, so no NPM_TOKEN is required.
npm version patch
git push --follow-tagsLicense
MIT — see LICENSE.
