stigmergy 1.3.24-beta.0 → 1.3.26-beta.0
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "stigmergy",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.26-beta.0",
|
|
4
4
|
"description": "Stigmergy CLI - Multi-Agents Cross-AI CLI Tools Collaboration System",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"bin": {
|
|
@@ -115,22 +115,20 @@
|
|
|
115
115
|
},
|
|
116
116
|
"dependencies": {
|
|
117
117
|
"chalk": "^4.1.2",
|
|
118
|
-
"commander": "^
|
|
119
|
-
"inquirer": "^
|
|
118
|
+
"commander": "^14.0.2",
|
|
119
|
+
"inquirer": "^13.1.0",
|
|
120
120
|
"js-yaml": "^4.1.1",
|
|
121
121
|
"semver": "^7.7.3"
|
|
122
122
|
},
|
|
123
123
|
"devDependencies": {
|
|
124
|
-
"
|
|
125
|
-
"
|
|
126
|
-
"eslint": "^8.57.1",
|
|
127
|
-
"jest": "^29.7.0",
|
|
124
|
+
"eslint": "^9.39.2",
|
|
125
|
+
"jest": "^30.2.0",
|
|
128
126
|
"prettier": "^3.7.4",
|
|
129
|
-
"rimraf": "^6.1.2"
|
|
130
|
-
"webpack": "^5.104.1",
|
|
131
|
-
"webpack-cli": "^6.0.1",
|
|
132
|
-
"webpack-dev-server": "^5.2.2"
|
|
127
|
+
"rimraf": "^6.1.2"
|
|
133
128
|
},
|
|
129
|
+
"optionalDependencies": {},
|
|
130
|
+
"peerDependencies": {},
|
|
131
|
+
"bundledDependencies": [],
|
|
134
132
|
"config": {
|
|
135
133
|
"encoding": "ansi",
|
|
136
134
|
"platform": "nodejs-first",
|
|
@@ -491,9 +491,9 @@ class ResumeSessionCommand {
|
|
|
491
491
|
});
|
|
492
492
|
|
|
493
493
|
response += `💡 **使用方法:**\n`;
|
|
494
|
-
response += `• 'stigmergy resume
|
|
495
|
-
response += `• 'stigmergy resume
|
|
496
|
-
response += `• 'stigmergy resume
|
|
494
|
+
response += `• 'stigmergy resume <数字>' - 显示指定数量的会话\n`;
|
|
495
|
+
response += `• 'stigmergy resume <cli>' - 查看特定CLI的会话\n`;
|
|
496
|
+
response += `• 'stigmergy resume <cli> <数字>' - 查看特定CLI的指定数量会话`;
|
|
497
497
|
|
|
498
498
|
return response;
|
|
499
499
|
}
|
|
@@ -680,23 +680,18 @@ module.exports.printResumeHelp = function() {
|
|
|
680
680
|
console.log(`
|
|
681
681
|
ResumeSession - Cross-CLI session recovery and history management
|
|
682
682
|
|
|
683
|
-
Usage: stigmergy resume [
|
|
683
|
+
Usage: stigmergy resume [cli] [limit]
|
|
684
684
|
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
--limit <num> Maximum sessions to show (default: 10)
|
|
689
|
-
--format <type> Output format: summary, timeline, detailed, context
|
|
690
|
-
--today Show today's sessions only
|
|
691
|
-
--week Show sessions from last 7 days
|
|
692
|
-
--month Show sessions from last 30 days
|
|
685
|
+
Arguments:
|
|
686
|
+
cli CLI tool to filter (claude, gemini, qwen, iflow, codebuddy, codex, qodercli)
|
|
687
|
+
limit Maximum number of sessions to show (default: 10)
|
|
693
688
|
|
|
694
689
|
Examples:
|
|
695
690
|
stigmergy resume
|
|
696
|
-
stigmergy resume
|
|
697
|
-
stigmergy resume
|
|
698
|
-
stigmergy resume
|
|
699
|
-
stigmergy resume
|
|
691
|
+
stigmergy resume 5
|
|
692
|
+
stigmergy resume iflow
|
|
693
|
+
stigmergy resume iflow 5
|
|
694
|
+
stigmergy resume claude 3
|
|
700
695
|
`);
|
|
701
696
|
};
|
|
702
697
|
|
package/src/cli/router-beta.js
CHANGED
|
@@ -331,9 +331,13 @@ async function main() {
|
|
|
331
331
|
program
|
|
332
332
|
.command('resume')
|
|
333
333
|
.description('Resume session - Cross-CLI session recovery and history management')
|
|
334
|
-
.argument('[
|
|
334
|
+
.argument('[cli]', 'CLI tool to filter (claude, gemini, qwen, iflow, codebuddy, codex, qodercli)')
|
|
335
|
+
.argument('[limit]', 'Maximum number of sessions to show')
|
|
335
336
|
.option('-v, --verbose', 'Verbose output')
|
|
336
|
-
.action(async (
|
|
337
|
+
.action(async (cli, limit, options) => {
|
|
338
|
+
const args = [];
|
|
339
|
+
if (cli) args.push(cli);
|
|
340
|
+
if (limit) args.push(limit);
|
|
337
341
|
await handleResumeCommand(args, options);
|
|
338
342
|
});
|
|
339
343
|
|
package/src/core/cli_tools.js
CHANGED
|
@@ -663,7 +663,8 @@ async function checkInstallation(toolName) {
|
|
|
663
663
|
const result = spawnSync(versionCmd.split(' ')[0], versionCmd.split(' ').slice(1), {
|
|
664
664
|
encoding: 'utf8',
|
|
665
665
|
shell: true,
|
|
666
|
-
timeout: 5000
|
|
666
|
+
timeout: 3000, // 减少超时时间从 5000 到 3000
|
|
667
|
+
stdio: ['ignore', 'pipe', 'pipe'] // 添加 stdio 配置
|
|
667
668
|
});
|
|
668
669
|
|
|
669
670
|
if (result.status === 0) {
|
|
@@ -84,11 +84,34 @@ class BuiltinSkillsDeployer {
|
|
|
84
84
|
async deployToCLI(skill, cliName) {
|
|
85
85
|
try {
|
|
86
86
|
const cliHomeDir = path.join(os.homedir(), `.${cliName}`);
|
|
87
|
-
|
|
87
|
+
|
|
88
|
+
// Check if CLI exists
|
|
89
|
+
if (!fs.existsSync(cliHomeDir)) {
|
|
90
|
+
console.warn(`[BUILTIN_SKILLS] CLI not found: ${cliName} (${cliHomeDir})`);
|
|
91
|
+
return { success: false, cliName, skillName: skill.name, error: 'CLI not installed' };
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
// Ensure skills directory exists
|
|
95
|
+
const cliSkillsRootDir = path.join(cliHomeDir, 'skills');
|
|
96
|
+
if (!fs.existsSync(cliSkillsRootDir)) {
|
|
97
|
+
try {
|
|
98
|
+
fs.mkdirSync(cliSkillsRootDir, { recursive: true });
|
|
99
|
+
} catch (error) {
|
|
100
|
+
console.error(`[BUILTIN_SKILLS] Failed to create skills root directory for ${cliName}:`, error.message);
|
|
101
|
+
return { success: false, cliName, skillName: skill.name, error: error.message };
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
const cliSkillsDir = path.join(cliSkillsRootDir, skill.name);
|
|
88
106
|
|
|
89
107
|
// Create skills directory
|
|
90
108
|
if (!fs.existsSync(cliSkillsDir)) {
|
|
91
|
-
|
|
109
|
+
try {
|
|
110
|
+
fs.mkdirSync(cliSkillsDir, { recursive: true });
|
|
111
|
+
} catch (error) {
|
|
112
|
+
console.error(`[BUILTIN_SKILLS] Failed to create skills directory for ${cliName}:`, error.message);
|
|
113
|
+
return { success: false, cliName, skillName: skill.name, error: error.message };
|
|
114
|
+
}
|
|
92
115
|
}
|
|
93
116
|
|
|
94
117
|
// Copy skill files
|
|
@@ -97,12 +120,18 @@ class BuiltinSkillsDeployer {
|
|
|
97
120
|
const sourcePath = path.join(this.skillsBaseDir, file.source);
|
|
98
121
|
const destPath = path.join(cliSkillsDir, path.basename(file.destination));
|
|
99
122
|
|
|
100
|
-
if (fs.existsSync(sourcePath)) {
|
|
123
|
+
if (!fs.existsSync(sourcePath)) {
|
|
124
|
+
console.warn(`[BUILTIN_SKILLS] Source file not found: ${sourcePath}`);
|
|
125
|
+
continue;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
try {
|
|
101
129
|
const content = fs.readFileSync(sourcePath, 'utf8');
|
|
102
130
|
fs.writeFileSync(destPath, content);
|
|
103
131
|
console.log(`[BUILTIN_SKILLS] Deployed ${file.source} to ${cliName}`);
|
|
104
|
-
}
|
|
105
|
-
console.
|
|
132
|
+
} catch (error) {
|
|
133
|
+
console.error(`[BUILTIN_SKILLS] Failed to copy ${file.source} to ${cliName}:`, error.message);
|
|
134
|
+
return { success: false, cliName, skillName: skill.name, error: error.message };
|
|
106
135
|
}
|
|
107
136
|
}
|
|
108
137
|
|