tsunami-code 3.12.2 → 3.12.4
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/index.js +5 -2
- package/lib/ui.js +8 -0
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
import { listMemories, readMemory, saveMemory, deleteMemory, getMemdirPath } from './lib/memdir.js';
|
|
28
28
|
import { execSync, spawn } from 'child_process';
|
|
29
29
|
|
|
30
|
-
const VERSION = '3.12.
|
|
30
|
+
const VERSION = '3.12.4';
|
|
31
31
|
const CONFIG_DIR = join(os.homedir(), '.tsunami-code');
|
|
32
32
|
const CONFIG_FILE = join(CONFIG_DIR, 'config.json');
|
|
33
33
|
const DEFAULT_SERVER = 'https://radiometric-reita-amuck.ngrok-free.dev';
|
|
@@ -1314,6 +1314,7 @@ Output ONLY the TSUNAMI.md content, starting with "# Project: <name>"`;
|
|
|
1314
1314
|
const spinner = createSpinner();
|
|
1315
1315
|
const turnStart = Date.now();
|
|
1316
1316
|
let firstToken = true;
|
|
1317
|
+
let bashCount = 0;
|
|
1317
1318
|
let toolTimers = {}; // track per-tool duration
|
|
1318
1319
|
|
|
1319
1320
|
spinner.start();
|
|
@@ -1339,6 +1340,7 @@ Output ONLY the TSUNAMI.md content, starting with "# Project: <name>"`;
|
|
|
1339
1340
|
spinner.stop();
|
|
1340
1341
|
const elapsed = toolTimers[toolName] != null ? Date.now() - toolTimers[toolName] : null;
|
|
1341
1342
|
toolTimers[toolName] = Date.now();
|
|
1343
|
+
if (toolName === 'Bash') bashCount++;
|
|
1342
1344
|
printToolCall(toolName, toolArgs, elapsed);
|
|
1343
1345
|
spinner.start();
|
|
1344
1346
|
firstToken = true;
|
|
@@ -1353,7 +1355,8 @@ Output ONLY the TSUNAMI.md content, starting with "# Project: <name>"`;
|
|
|
1353
1355
|
|
|
1354
1356
|
const elapsed = ((Date.now() - turnStart) / 1000).toFixed(1);
|
|
1355
1357
|
const tok = tokenStats.output > 0 ? ` · ${tokenStats.output - (_outputTokens || 0)} tok` : '';
|
|
1356
|
-
|
|
1358
|
+
const shells = bashCount > 0 ? ` · ${bashCount} shell${bashCount === 1 ? '' : 's'} ran` : '';
|
|
1359
|
+
process.stdout.write(dim(`\n ✻ Cogitated for ${elapsed}s${shells}${tok}\n`));
|
|
1357
1360
|
|
|
1358
1361
|
// Token estimation
|
|
1359
1362
|
const inputChars = fullMessages.reduce((s, m) => s + (typeof m.content === 'string' ? m.content.length : 0), 0);
|
package/lib/ui.js
CHANGED
|
@@ -154,6 +154,14 @@ export function createUI({ planMode: initPlanMode = false, onLine, onTab, onExit
|
|
|
154
154
|
drawBox();
|
|
155
155
|
goOutputArea();
|
|
156
156
|
process.stdout.write('\n');
|
|
157
|
+
// Echo submitted message with grey background (Claude Code style)
|
|
158
|
+
if (line) {
|
|
159
|
+
const cols = process.stdout.columns || 80;
|
|
160
|
+
const echo = chalk.level > 0
|
|
161
|
+
? chalk.bgGray.white((' ❯ ' + line).padEnd(cols))
|
|
162
|
+
: dim(' ❯ ' + line);
|
|
163
|
+
process.stdout.write(echo + '\n');
|
|
164
|
+
}
|
|
157
165
|
onLine(line);
|
|
158
166
|
}
|
|
159
167
|
return;
|