@eventmodelers/cli 1.0.147 → 1.0.148

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.
@@ -48,12 +48,38 @@ export async function latestPublishedVersion({ cachePath, now = Date.now(), fetc
48
48
  }
49
49
  }
50
50
 
51
+ // A loud banner, so a stale CLI is not missed among the startup output — an old CLI can lack
52
+ // features the board expects (e.g. chat), and npx happily reuses a cached copy. Bold yellow
53
+ // when stderr is a terminal (NO_COLOR respected); plain box otherwise, so piped output stays clean.
54
+ function updateBanner(currentVersion, latestVersion) {
55
+ const paint = process.stderr.isTTY && !process.env.NO_COLOR ? (t) => `\x1b[1;33m${t}\x1b[0m` : (t) => t;
56
+ const lines = [
57
+ '!! UPDATE REQUIRED — YOUR EVENTMODELERS CLI IS OUT OF DATE !!',
58
+ '',
59
+ `Installed: ${currentVersion} Latest: ${latestVersion}`,
60
+ '',
61
+ 'Update now:',
62
+ '',
63
+ ' npx @eventmodelers/cli@latest <command>',
64
+ ' (still old? clear the npx cache: rm -rf ~/.npm/_npx)',
65
+ '',
66
+ ' npm i -g @eventmodelers/cli@latest (global install)',
67
+ '',
68
+ 'Old versions miss features the board expects —',
69
+ 'e.g. agents that do not reply in the board chat.',
70
+ ];
71
+ const width = Math.max(...lines.map((l) => l.length));
72
+ const bar = '█'.repeat(width + 6);
73
+ const body = lines.map((l) => `██ ${l.padEnd(width)} ██`);
74
+ return paint(['', bar, ...body, bar, ''].join('\n'));
75
+ }
76
+
51
77
  // Hint lines for everything that's behind: this CLI against npm, and each installed kit
52
78
  // against the CLI running now (its install manifest records the version that wrote it).
53
79
  export function updateHints({ currentVersion, latestVersion, kitDirs = [], cwd = process.cwd() }) {
54
80
  const hints = [];
55
81
  if (latestVersion && compareVersions(currentVersion, latestVersion) < 0) {
56
- hints.push(`💡 A new eventmodelers CLI is available: ${currentVersion} → ${latestVersion}. Update with: npm i -g @eventmodelers/cli@latest (or use npx @eventmodelers/cli@latest)`);
82
+ hints.push(updateBanner(currentVersion, latestVersion));
57
83
  }
58
84
  for (const kitDir of kitDirs) {
59
85
  const reinit = REINIT_COMMANDS[basename(kitDir)];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eventmodelers/cli",
3
- "version": "1.0.147",
3
+ "version": "1.0.148",
4
4
  "description": "Eventmodelers CLI — real-time Claude agent + skills for Claude Code, for any stack (Node, Supabase, Axon, OpenCQRS, UmaDB, Kurrent, or modeling-only)",
5
5
  "type": "module",
6
6
  "bin": {