-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't send newlines to the shell from Terminal Chat #17994
base: feature/llm
Are you sure you want to change the base?
Conversation
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is in lieu of having good bracketed paste support in conhost and powershell
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm a little confused why we don't just remove the \r
replacement entirely. \r
is what the shell considers to be an "Enter" press so if we send \n
delimited strings the shell will treat it as a multi-line paste. If that is correct, then the &
/ ;
replacement seems like the wrong way to solve this.
Unfortunately the way we send the text to the shell (i.e. via a |
|
What was the issue with
Right, that makes sense. |
#15788. We closed it because we stipulated there should actually be |
Summary of the Pull Request
When a multiline code block is clicked in Terminal chat, the first command gets run before the user presses 'Enter'. This commit fixes that by separating the code lines by the delimiter appropriate to the shell (
&
for cmd,;
for everything else).Validation Steps Performed
Newlines get replaced with the appropriate delimiter
PR Checklist