px2cc 2.1.0 → 2.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin.js +7 -9
- package/cli.js +7 -8
- package/package.json +2 -2
package/bin.js
CHANGED
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
|
-
* Px2CC 启动器 -
|
|
5
|
-
* 直接导入cli.js,跨平台兼容
|
|
4
|
+
* Px2CC 启动器 - Windows兼容版本
|
|
6
5
|
*/
|
|
7
6
|
|
|
8
7
|
// 设置环境变量来抑制PromptX内部日志
|
|
9
8
|
process.env.LOG_LEVEL = 'silent';
|
|
10
9
|
|
|
11
|
-
//
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
import('./cli.js');
|
|
10
|
+
// 简单直接的导入方式 - Windows兼容
|
|
11
|
+
import('./cli.js').catch(error => {
|
|
12
|
+
console.error('启动失败:', error.message);
|
|
13
|
+
console.error('请检查Node.js版本是否 >= 18.0.0');
|
|
14
|
+
process.exit(1);
|
|
15
|
+
});
|
package/cli.js
CHANGED
|
@@ -299,7 +299,7 @@ async function installRole(selectedRole, installType, claudeDir, manager, select
|
|
|
299
299
|
}
|
|
300
300
|
|
|
301
301
|
// 主程序入口
|
|
302
|
-
async function main() {
|
|
302
|
+
export async function main() {
|
|
303
303
|
try {
|
|
304
304
|
showWelcome();
|
|
305
305
|
|
|
@@ -373,10 +373,9 @@ async function main() {
|
|
|
373
373
|
}
|
|
374
374
|
}
|
|
375
375
|
|
|
376
|
-
// 运行主程序
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
}
|
|
376
|
+
// 运行主程序 - Windows兼容版本
|
|
377
|
+
// 通过bin.js调用时直接执行,通过import调用时也执行
|
|
378
|
+
main().catch(error => {
|
|
379
|
+
console.error(chalk.red('❌ 程序异常:'), error.message);
|
|
380
|
+
process.exit(1);
|
|
381
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "px2cc",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.2",
|
|
4
4
|
"description": "CLI tool that implements complete PromptX Action flow in Claude Code - role activation, dependency loading, cognition networks & memory systems",
|
|
5
5
|
"main": "cli.js",
|
|
6
6
|
"type": "module",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"author": "PromptX Bridge Team",
|
|
39
39
|
"license": "MIT",
|
|
40
40
|
"engines": {
|
|
41
|
-
"node": ">=
|
|
41
|
+
"node": ">=18.0.0"
|
|
42
42
|
},
|
|
43
43
|
"repository": {
|
|
44
44
|
"type": "git",
|