@seamnet/client 0.14.4 → 0.14.5
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/seam.js +7 -1
- package/package.json +1 -1
package/bin/seam.js
CHANGED
|
@@ -457,8 +457,14 @@ async function cmdCc(subAction, restArgs) {
|
|
|
457
457
|
if (!target) output(false, `session "${values.session}" not found`);
|
|
458
458
|
if (!target.cc) output(false, `session "${values.session}": CC not running`);
|
|
459
459
|
try {
|
|
460
|
+
// 分两步:先发文本(literal),再单独发 Enter
|
|
461
|
+
// CC 用 raw terminal mode,合在一起发会丢回车
|
|
460
462
|
execSync(
|
|
461
|
-
`tmux send-keys -t "${values.session}" ${JSON.stringify(values.text)}
|
|
463
|
+
`tmux send-keys -t "${values.session}" -l ${JSON.stringify(values.text)}`,
|
|
464
|
+
{ timeout: 5000 }
|
|
465
|
+
);
|
|
466
|
+
execSync(
|
|
467
|
+
`tmux send-keys -t "${values.session}" Enter`,
|
|
462
468
|
{ timeout: 5000 }
|
|
463
469
|
);
|
|
464
470
|
output(true, { session: values.session, sent: values.text });
|