vscode-remote-release icon indicating copy to clipboard operation
vscode-remote-release copied to clipboard

Allow to copy from remote tmux to local clipboard

Open pszypowicz opened this issue 2 years ago • 10 comments

I'm a tmux user who copies text from terminal using keyboard.

In tmux, I'm able to enter "copy mode", select text, press "Enter" and selected text will show up in the Clipboard.

Unfortunately I'm unable to achieve it with Remote SSH extension. However it is working as expected when I'm connect via standard SSH and use tmux.

To be honest I do not know if that's a "Bug" of "Feature Request"

pszypowicz avatar Feb 15 '23 12:02 pszypowicz

cc @eleanorjboyd I'm making this as a feature request, but if you think it's a bug, please just let me know.

bamurtaugh avatar Feb 22 '23 21:02 bamurtaugh

This feature request is now a candidate for our backlog. The community has 60 days to upvote the issue. If it receives 10 upvotes we will move it to our backlog. If not, we will close it. To learn more about how we handle feature requests, please see our documentation.

Happy Coding!

vscodenpa avatar Feb 22 '23 21:02 vscodenpa

This is happening because of the way the SSH extension works, VS Code uses SSH to communicate with the remote, but on the remote we launch a regular local shell so the text is copied but it's copied on the remote's clipboard, not the local clipboard.

Given this, I think feature request is right.

Tyriar avatar Feb 28 '23 13:02 Tyriar

@bamurtaugh It seems we have 10 upvotes :)

pszypowicz avatar Mar 01 '23 14:03 pszypowicz

Can we get this fixed please? It really makes tmux useless on VSCode.

kishykumar avatar Mar 20 '23 06:03 kishykumar

+1, I have remote copy-paste working with tmux on a rhel host via iterm2 on a mac, so I dont think it's a limitation with ssh itself

kdkavanagh avatar Apr 03 '23 14:04 kdkavanagh

I don't believe this is limited to just Mac vscode. I am running Windows 10 with vscode 1.79.1 with an Ubuntu LTS remote SSH and seeing the same behavior. Copy/paste to the local clipboard works fine for other terminal sessions, but after trying various things found on the web I can't get the copy/paste behavior through tmux to work as expected.

raven42 avatar Jun 15 '23 14:06 raven42

Also vote for this feature.

I configured remote-ssh to open tmux as default integrated terminal profile.

After tmux is launched, I can't copy and paste using vim-like copy-mode-vi by pressing y. I managed to use a tmux-plugin called tmux-yank to copy selected words into the command line, but they won't go inside my local macbook's system clipboard. Now I temporarily hold alt key to copy via mouse, but being able to yank directly via y would be lovely!

Thank you for implementing this feature!

zhuoqun-chen avatar Aug 02 '23 06:08 zhuoqun-chen

I think https://github.com/xtermjs/xterm.js/issues/3260 is related?

avamsi avatar Aug 19 '23 06:08 avamsi

Also vote for this feature

duenzo avatar Feb 16 '24 12:02 duenzo

+1 for this feature

navratiljan avatar Feb 26 '24 06:02 navratiljan

/duplicate https://github.com/microsoft/vscode/issues/193508

Tyriar avatar Apr 22 '24 09:04 Tyriar