mirror of
https://github.com/stackblitz/bolt.new
synced 2025-02-06 04:48:04 +00:00
fix: added wait till terminal prompt for bolt shell execution
This commit is contained in:
parent
0ee3736297
commit
69c0bf5873
@ -1 +1 @@
|
|||||||
{ "commit": "1e72d52278730f7d22448be9d5cf2daf12559486", "version": "0.0.2" }
|
{ "commit": "0ee373629789f01fb9f54f6747735b51a94a5562" }
|
||||||
|
@ -105,6 +105,7 @@ export class BoltShell {
|
|||||||
* this.#shellInputStream?.write('\x03');
|
* this.#shellInputStream?.write('\x03');
|
||||||
*/
|
*/
|
||||||
this.terminal.input('\x03');
|
this.terminal.input('\x03');
|
||||||
|
await this.waitTillOscCode('prompt');
|
||||||
|
|
||||||
if (state && state.executionPrms) {
|
if (state && state.executionPrms) {
|
||||||
await state.executionPrms;
|
await state.executionPrms;
|
||||||
@ -145,6 +146,10 @@ export class BoltShell {
|
|||||||
terminalOutput.pipeTo(
|
terminalOutput.pipeTo(
|
||||||
new WritableStream({
|
new WritableStream({
|
||||||
write(data) {
|
write(data) {
|
||||||
|
/*
|
||||||
|
* const [, osc] = data.match(/\x1b\]654;([^\x07]+)\x07/) || [];
|
||||||
|
* console.log('terminal onData', { data,osc });
|
||||||
|
*/
|
||||||
if (!isInteractive) {
|
if (!isInteractive) {
|
||||||
const [, osc] = data.match(/\x1b\]654;([^\x07]+)\x07/) || [];
|
const [, osc] = data.match(/\x1b\]654;([^\x07]+)\x07/) || [];
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user