groundcrew-cli 0.15.4 → 0.15.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/dist/index.js +6 -0
- package/package.json +1 -1
- package/src/index.ts +10 -0
package/dist/index.js
CHANGED
|
@@ -468,6 +468,12 @@ function setupInlineSuggestions(rl) {
|
|
|
468
468
|
};
|
|
469
469
|
process.stdin.on("keypress", (_ch, key) => {
|
|
470
470
|
if (!key) return;
|
|
471
|
+
if (key.name === "return" && key.shift) {
|
|
472
|
+
const line = rl.line;
|
|
473
|
+
rl.line = line + "\\";
|
|
474
|
+
rl.cursor = rl.line.length;
|
|
475
|
+
return;
|
|
476
|
+
}
|
|
471
477
|
clearGhost();
|
|
472
478
|
if (key.name !== "return" && key.name !== "tab") {
|
|
473
479
|
setImmediate(showGhost);
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -625,6 +625,16 @@ function setupInlineSuggestions(rl: readline.Interface): void {
|
|
|
625
625
|
|
|
626
626
|
process.stdin.on("keypress", (_ch: string, key: any) => {
|
|
627
627
|
if (!key) return;
|
|
628
|
+
|
|
629
|
+
// Shift+Enter: insert newline marker instead of submitting
|
|
630
|
+
if (key.name === "return" && key.shift) {
|
|
631
|
+
// Append backslash to trigger line continuation, then simulate Enter
|
|
632
|
+
const line = (rl as any).line as string;
|
|
633
|
+
(rl as any).line = line + "\\";
|
|
634
|
+
(rl as any).cursor = (rl as any).line.length;
|
|
635
|
+
return;
|
|
636
|
+
}
|
|
637
|
+
|
|
628
638
|
clearGhost();
|
|
629
639
|
if (key.name !== "return" && key.name !== "tab") {
|
|
630
640
|
setImmediate(showGhost);
|