gm-gc 2.0.234 → 2.0.236
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/gemini-extension.json
CHANGED
|
@@ -296,10 +296,12 @@ const run = () => {
|
|
|
296
296
|
let out = stripFooter((r.stdout || '') + (r.stderr || ''));
|
|
297
297
|
const bg = out.match(/Task ID:\s*(task_\S+)/);
|
|
298
298
|
if (bg) {
|
|
299
|
-
runGmExec(['sleep', bg[1], '
|
|
299
|
+
runGmExec(['sleep', bg[1], '15'], { timeout: 25000 });
|
|
300
300
|
const sr = runGmExec(['status', bg[1]], { timeout: 15000 });
|
|
301
|
-
|
|
302
|
-
|
|
301
|
+
const statusOut = stripFooter((sr.stdout || '') + (sr.stderr || ''));
|
|
302
|
+
const stillRunning = /Status:\s*running/i.test(statusOut);
|
|
303
|
+
out = statusOut;
|
|
304
|
+
if (!stillRunning) runGmExec(['close', bg[1]], { timeout: 10000 });
|
|
303
305
|
}
|
|
304
306
|
return out;
|
|
305
307
|
};
|
package/hooks/stop-hook.js
CHANGED
|
@@ -22,14 +22,10 @@ const run = () => {
|
|
|
22
22
|
if (fs.existsSync(prdFile)) {
|
|
23
23
|
const prdContent = fs.readFileSync(prdFile, 'utf-8').trim();
|
|
24
24
|
if (prdContent.length > 0) {
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
ok: false,
|
|
30
|
-
reason: `Work items remain in ${prdFile}. Remove completed items as they finish. Current items:\n\n${prdContent}`
|
|
31
|
-
};
|
|
32
|
-
}
|
|
25
|
+
return {
|
|
26
|
+
ok: false,
|
|
27
|
+
reason: `Work items remain in ${prdFile}. Remove completed items as they finish. Delete the file when all items are done.\n\n${prdContent}`
|
|
28
|
+
};
|
|
33
29
|
}
|
|
34
30
|
}
|
|
35
31
|
return { ok: true };
|