Skip to content
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

Fix multi line paste detection and filtering #8634

Merged
8 commits merged into from
Jan 8, 2021
Merged

Fix multi line paste detection and filtering #8634

8 commits merged into from
Jan 8, 2021

Conversation

PankajBhojwani
Copy link
Contributor

@PankajBhojwani PankajBhojwani commented Dec 21, 2020

  • Detect \r when warning about multi line paste
  • Translate \n to \r on paste

PR Checklist

Validation Steps Performed

Manual testing

src/cascadia/TerminalApp/TerminalPage.cpp Outdated Show resolved Hide resolved
src/cascadia/TerminalApp/TerminalPage.cpp Outdated Show resolved Hide resolved
src/cascadia/TerminalApp/TerminalPage.cpp Outdated Show resolved Hide resolved
src/cascadia/TerminalControl/TermControl.cpp Outdated Show resolved Hide resolved
@ghost ghost added Area-User Interface Issues pertaining to the user interface of the Console or Terminal Issue-Bug It either shouldn't be doing this or needs an investigation. Priority-3 A description (P3) Product-Terminal The new Windows Terminal. labels Jan 7, 2021
@PankajBhojwani PankajBhojwani changed the title [DRAFT] Fixes for multi line paste detection and filtering Fixes for multi line paste detection and filtering Jan 7, 2021
@PankajBhojwani PankajBhojwani marked this pull request as ready for review January 7, 2021 20:44
Copy link
Member

@DHowett DHowett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one shot, one target eliminated. excellent work

@ghost ghost added Area-TerminalControl Issues pertaining to the terminal control (input, selection, keybindings, mouse interaction, etc.) Impact-Correctness It be wrong. labels Jan 7, 2021
@DHowett DHowett changed the title Fixes for multi line paste detection and filtering Fix multi line paste detection and filtering Jan 7, 2021
@DHowett DHowett added the AutoMerge Marked for automatic merge by the bot when requirements are met label Jan 7, 2021
@ghost
Copy link

ghost commented Jan 7, 2021

Hello @DHowett!

Because this pull request has the AutoMerge label, I will be glad to assist with helping to merge this pull request once all check-in policies pass.

p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (@msftbot) and give me an instruction to get started! Learn more here.

@ghost ghost added Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something and removed Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something labels Jan 7, 2021
@DHowett DHowett added the Needs-Second It's a PR that needs another sign-off label Jan 8, 2021
@ghost ghost requested review from zadjii-msft and miniksa January 8, 2021 02:26
Copy link
Member

@zadjii-msft zadjii-msft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay that seems fine. I'd feel better with a test for this, since it's a little hard to follow, but there's not a good way of doing TermControl unittests at the moment, so I just stuck this on #7001 for now.

@ghost ghost merged commit 49d0085 into main Jan 8, 2021
@ghost ghost deleted the dev/pabhoj/paste_fix branch January 8, 2021 10:44
DHowett pushed a commit that referenced this pull request Jan 25, 2021
- Detect `\r` when warning about multi line paste
- Translate `\n` to `\r` on paste

## PR Checklist
* [x] Closes #8601
* [x] Closes #5821

## Validation Steps Performed
Manual testing

(cherry picked from commit 49d0085)
@ghost
Copy link

ghost commented Jan 28, 2021

🎉Windows Terminal v1.5.10271.0 has been released which incorporates this pull request.:tada:

Handy links:

@ghost
Copy link

ghost commented Jan 28, 2021

🎉Windows Terminal Preview v1.6.10272.0 has been released which incorporates this pull request.:tada:

Handy links:

mpela81 pushed a commit to mpela81/terminal that referenced this pull request Jan 28, 2021
- Detect `\r` when warning about multi line paste
- Translate `\n` to `\r` on paste

## PR Checklist
* [x] Closes microsoft#8601
* [x] Closes microsoft#5821

## Validation Steps Performed
Manual testing
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-TerminalControl Issues pertaining to the terminal control (input, selection, keybindings, mouse interaction, etc.) Area-User Interface Issues pertaining to the user interface of the Console or Terminal AutoMerge Marked for automatic merge by the bot when requirements are met Impact-Correctness It be wrong. Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Second It's a PR that needs another sign-off Priority-3 A description (P3) Product-Terminal The new Windows Terminal.
Projects
None yet
4 participants