-
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
Copy Paste is from Terminal(Powershell) -> VSCode is just broken #9696
Comments
Well, even worse, it's seemingly rather inconsistent when making this repro video: https://youtu.be/YUTGcPrOueA (enjoy the extra win10 bug of being unable to close the Terminal repeatedly). I can't tell what I'm doing differently between when it works correctly vs not. |
You’re disappointed. I get it. But can you elaborate on the “useless text” part? A screenshot would be nice. I have no idea what exactly the issue is after reading all your complaints. |
Oh. A YouTube video. Didn’t see that. But, I’m in China so that video can be problem for me. |
Sometimes when you copy-paste from the terminal, it respects line breaks, other times it copies a single line of text with tons of spaces embedded. Sorry the emotion got in the way of a better issue description; a screenshot would've made sense. I can provide one now: Again, sometimes it copies and pastes as expected, sometimes this, it's hard to tell when each will happen. When making this screenshot, it actually worked correctly several times before I stopped/restarted and then it reprod. (And the same behavior is observed with |
What the string is between Logo and prompt? If you are using custom $profile then maybe something wrong in it. Something that may affect the text being copied. |
The string between the logo and the prompt is the output of But, again, the video shows multiple attempts. All attempts include that line of text. And yet it only pastes correctly about half the time. |
Are you always copying in the same way? i.e. always pressing the same keybinding or always right clicking, with the same modifiers each time? |
Is #6901 somewhat related to this? |
Very likely, though, I'm more confused here that the same rows of text are sometimes copying with newlines and sometimes without. The bug that's hiding in #6901 seems more to be that conpty doesn't always mark the rows as wrapped correctly. In that case, the lines would consistently copy wrong, because they're in the buffer wrong. In this issue's case, the lines are sometimes copying with newlines and sometimes without, and that's mysterious and new. |
This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. |
We shouldn't necessarily let the bot mark this one just yet. Not sure whether this is a new issue or another face of 6901. |
Oh, I'm used to holding shift while selecting things (tmux, etc). So I hold shift, drag, right click. If I'm still holding shift when I right click, it's copied as a single line. Now I'm worried this is maybe in fact expected behavior. |
It most certainly is expected behavior: https://github.com/microsoft/terminal/blob/main/src/cascadia/TerminalControl/TermControl.cpp#L1443 where |
Windows Terminal version (or Windows build number)
1.7.572.0
Other Software
Nope, just plain old Powershell built into Win10
Steps to reproduce
Start Terminal.
Copy some text.
Paste it into VSCodium.
Expected Behavior
It is readable? Usable? Not useless?
Actual Behavior
It is indeed a single useless line of text.
I don't feel like I've always had this issue, maybe something bad slipped into the Preview builds? I don't know, for know I just am not using Terminal right now.
(Also, unrelated, but complete LOL at the fact that "Cod" still can't autocomplete to "VSCodium" in Win10. Stunning.)
The text was updated successfully, but these errors were encountered: