@yemi33/minions 0.1.1933 → 0.1.1935
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/minions.js +33 -4
- package/engine/copilot-models.json +1 -1
- package/package.json +1 -1
package/bin/minions.js
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
* minions add <project-dir> Link a project (interactive)
|
|
9
9
|
* minions remove <project-dir> Unlink a project
|
|
10
10
|
* minions list List linked projects
|
|
11
|
-
* minions update
|
|
11
|
+
* minions update [--no-wait] Update to latest version (--no-wait backgrounds the post-update restart)
|
|
12
12
|
* minions version Show installed and package versions
|
|
13
13
|
* minions doctor Check prerequisites and runtime health
|
|
14
14
|
* minions restart [--open] Start engine + dashboard (--open forces a new browser tab)
|
|
@@ -604,6 +604,28 @@ function runPostUpdateRestart() {
|
|
|
604
604
|
process.exit(1);
|
|
605
605
|
}
|
|
606
606
|
|
|
607
|
+
// Fire-and-forget variant for `minions update --no-wait`. The npm + init phases
|
|
608
|
+
// have already completed synchronously, so package-install failures surface
|
|
609
|
+
// normally; only the long-tail engine/dashboard restart + health check is
|
|
610
|
+
// backgrounded. stdio is redirected to a log so the user can postmortem if the
|
|
611
|
+
// restart fails after the parent has exited.
|
|
612
|
+
function runPostUpdateRestartDetached() {
|
|
613
|
+
const initScript = path.join(PKG_ROOT, 'bin', 'minions.js');
|
|
614
|
+
const out = _openStdioLog('update-restart-stdio.log');
|
|
615
|
+
const err = _openStdioLog('update-restart-stdio.log');
|
|
616
|
+
const proc = spawn(process.execPath, [initScript, 'restart'], {
|
|
617
|
+
cwd: process.cwd(),
|
|
618
|
+
env: { ...process.env, MINIONS_HOME },
|
|
619
|
+
stdio: ['ignore', out, err],
|
|
620
|
+
detached: true,
|
|
621
|
+
windowsHide: true,
|
|
622
|
+
});
|
|
623
|
+
proc.unref();
|
|
624
|
+
const logPath = path.join(MINIONS_HOME, 'engine', 'update-restart-stdio.log');
|
|
625
|
+
console.log(` Restart spawned in background (PID: ${proc.pid}); logs: ${logPath}`);
|
|
626
|
+
console.log(` Verify with: minions status\n`);
|
|
627
|
+
}
|
|
628
|
+
|
|
607
629
|
// ─── Version command ────────────────────────────────────────────────────────
|
|
608
630
|
|
|
609
631
|
function showVersion() {
|
|
@@ -668,7 +690,7 @@ if (!cmd || cmd === 'help' || cmd === '--help' || cmd === '-h') {
|
|
|
668
690
|
|
|
669
691
|
Setup:
|
|
670
692
|
minions init Bootstrap ~/.minions/ (first time)
|
|
671
|
-
minions update
|
|
693
|
+
minions update [--no-wait] Update to latest version (--no-wait backgrounds the restart)
|
|
672
694
|
minions version Show installed vs package version
|
|
673
695
|
minions doctor Check prerequisites and runtime health
|
|
674
696
|
minions add <project-dir> Link a project (interactive)
|
|
@@ -707,6 +729,7 @@ if (!cmd || cmd === 'help' || cmd === '--help' || cmd === '-h') {
|
|
|
707
729
|
} else if (cmd === 'init') {
|
|
708
730
|
init();
|
|
709
731
|
} else if (cmd === 'update') {
|
|
732
|
+
const noWait = rest.includes('--no-wait') || rest.includes('--detach');
|
|
710
733
|
console.log('\n Updating Minions...\n');
|
|
711
734
|
// Dev/symlink installs: PKG_ROOT === MINIONS_HOME — npm update is a no-op (symlink already
|
|
712
735
|
// points to the repo), and `minions init --force` would fail (cwd/.minions is inside PKG_ROOT).
|
|
@@ -726,9 +749,15 @@ if (!cmd || cmd === 'help' || cmd === '--help' || cmd === '-h') {
|
|
|
726
749
|
// the global shim while npm is still settling the updated install.
|
|
727
750
|
runPostUpdateInit();
|
|
728
751
|
}
|
|
729
|
-
// Restart engine + dashboard so they pick up the new code
|
|
752
|
+
// Restart engine + dashboard so they pick up the new code. With --no-wait the
|
|
753
|
+
// restart is spawned detached so the caller (e.g. a DevBox maintenance task)
|
|
754
|
+
// can return immediately without holding the parent open for the health poll.
|
|
730
755
|
console.log('\n Restarting engine and dashboard...\n');
|
|
731
|
-
|
|
756
|
+
if (noWait) {
|
|
757
|
+
runPostUpdateRestartDetached();
|
|
758
|
+
} else {
|
|
759
|
+
runPostUpdateRestart();
|
|
760
|
+
}
|
|
732
761
|
} else if (cmd === 'version' || cmd === '--version' || cmd === '-v') {
|
|
733
762
|
showVersion();
|
|
734
763
|
} else if (cmd === 'add' || cmd === 'remove' || cmd === 'list' || cmd === 'scan') {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yemi33/minions",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1935",
|
|
4
4
|
"description": "Multi-agent AI dev team that runs from ~/.minions/ — five autonomous agents share a single engine, dashboard, and knowledge base",
|
|
5
5
|
"bin": {
|
|
6
6
|
"minions": "bin/minions.js"
|