File tree Expand file tree Collapse file tree 2 files changed +15
-5
lines changed
codewhispererChat/controllers/chat/messenger Expand file tree Collapse file tree 2 files changed +15
-5
lines changed Original file line number Diff line number Diff line change @@ -345,12 +345,22 @@ export class Connector extends BaseConnector {
345
345
}
346
346
break
347
347
case 'run-shell-command' :
348
- if ( answer . header ) {
349
- answer . header . status = {
348
+ if ( Object . keys ( answer . header ! ) . length === 0 ) {
349
+ answer . header = {
350
+ body : '$ shell' ,
351
+ status : {
352
+ icon : 'ok' as MynahIconsType ,
353
+ text : 'Accepted' ,
354
+ status : 'success' ,
355
+ } ,
356
+ }
357
+ } else {
358
+ answer . header ! . status = {
350
359
icon : 'ok' as MynahIconsType ,
351
360
text : 'Accepted' ,
352
361
status : 'success' ,
353
362
}
363
+ answer . header ! . buttons = [ ]
354
364
}
355
365
break
356
366
case 'reject-shell-command' :
@@ -360,6 +370,7 @@ export class Connector extends BaseConnector {
360
370
text : 'Rejected' ,
361
371
status : 'error' ,
362
372
}
373
+ answer . header . buttons = [ ]
363
374
}
364
375
break
365
376
default :
Original file line number Diff line number Diff line change @@ -475,13 +475,12 @@ export class Messenger {
475
475
}
476
476
477
477
shellCommandHeader = {
478
- icon : 'code-block' as MynahIconsType ,
479
- body : 'shell' ,
478
+ body : '$ shell' ,
480
479
buttons : buttons ,
481
480
}
482
481
483
482
if ( validation . warning ) {
484
- message = validation . warning + message
483
+ message = validation . warning + message + '\nRun the command to proceed.\n'
485
484
}
486
485
} else if ( toolUse ?. name === ToolType . FsWrite ) {
487
486
const input = toolUse . input as unknown as FsWriteParams
You can’t perform that action at this time.
0 commit comments