refactor(pi-permission): extract shared bash-recovery package

- add @sikongjueluo/pi-permission-shared with recoverNativeBashCommand and its tests
- move the recovery module out of pi-permission-inner-cmd and import it from the shared package
- wire pi-permission-ai-judge to capture the UI-root session and recover the full bash command
- gate pi-permission-ai-judge registration on a UI-present root session
- add @types/node to pi-permission-ai-judge and allow its test script to pass with no tests
This commit is contained in:
2026-08-11 21:53:46 +08:00
parent 06b21a28a6
commit 2014e7f793
10 changed files with 139 additions and 22 deletions
+8 -1
View File
@@ -16,15 +16,22 @@
"@earendil-works/pi-coding-agent": "*",
"@gotgenes/pi-permission-system": ">=20.10.0"
},
"dependencies": {
"@sikongjueluo/pi-permission-shared": "workspace:*"
},
"bundledDependencies": [
"@sikongjueluo/pi-permission-shared"
],
"devDependencies": {
"@earendil-works/pi-ai": "*",
"@earendil-works/pi-coding-agent": "*",
"@gotgenes/pi-permission-system": ">=20.10.0",
"@types/node": "^26.0.0",
"typescript": "^5",
"vitest": "^3"
},
"scripts": {
"check": "tsc --noEmit",
"test": "vitest run"
"test": "vitest run --passWithNoTests"
}
}