Omár,

First, check to see if PuTTY is configured to do this at all. If tmux has focus, detach from the session with prefix,d (by default, this will be Ctrl-b, d). Then try to highlight with PuTTY, and see if the highlighted text gets copied to the clipboard.

If that doesn't work, then your issue is with PuTTY. Make sure you're using the latest version of PuTTY, and then it would be somewhere on the Selection section of the PuTTY Session Profile. I'm not in front of a system with PuTTY installed right now, so I'm not sure what you need to select on this page. But it should be pretty obvious that you're missing the copy-to-clipboard on highlight option.

If PuTTY can copy to clipboard with highlight outside of tmux, I'd kill your tmux server (`tmux kill-server`), and rename your ~/.tmux.conf (`mv ~/.tmux.conf{,.bak$(date +%F)}`) to start with a default tmux configuration. See if the problem persists in a new server/session started with the default config. If highlighting with the mouse in tmux in PuTTY works after that, then it's a setting in your original ~/.tmux.conf.

You'll probably want to remove any tmux mouse configuration, as that could very well be causing the problem, if a default/empty .tmux.conf works.


On Wed, Aug 16, 2023 at 02:58:14AM -0700, omár sweidán wrote:
I tried what you said, but my tmux is not copying  things directly to the
Windows clipboard by highlighting the text with the mouse. What should I change
in PuTTY selection settings?

Trey Blancher a következőt írta (2023. augusztus 3., csütörtök, 3:36:02 UTC+2):

   Omar,

   If I remember correctly, PuTTY by default copies any selected text to the
   Windows clipboard, just by highlighting the text with a mouse. You can
   modify
   this in the PuTTY Selection settings, which can be set per connection
   profile.
   To modify the default settings, make your changes and save it as the
   "Default
   Settings" profile.

   Note that PuTTY is likely not aware of any pane boundaries which might be
   visible in a tmux window, so be careful when you're selecting text in a
   tmux
   view that shows multiple panes. It may be best to use prefix+z to zoom into
   a
   pane before selecting.


   On Wed, Aug 02, 2023 at 02:01:07AM -0700, omár sweidán wrote:
   >Hello, All!
   >
   >I'm logging in to a Linux server from a Win10 machine via PuTTY. When I
   open a
   >text file with vim, I can use Ctrl-C/Ctrl-V to copy/paste from the text to
   a
   >Windows program. But if I use tmux with multiple tabs, the same thing does
   not
   >work. Can you please support?
   >
   >Omar Sweidan
   >
   >--
   >You received this message because you are subscribed to the Google Groups
   >"tmux-users" group.
   >To unsubscribe from this group and stop receiving emails from it, send an
   email
   >to [1]tmux-users+...@googlegroups.com.
   >To view this discussion on the web, visit [2][1]https://groups.google.com/
   d/msgid/
   >tmux-users/56375754-89d3-48da-90ea-0355117ef2dfn%[2]40googlegroups.com.
   >
   >References:
   >
   >[1] mailto:tmux-users+...@googlegroups.com
   >[2] [3]https://groups.google.com/d/msgid/tmux-users/
   56375754-89d3-48da-90ea-0355117ef2dfn%40googlegroups.com?utm_medium=email&
   utm_source=footer


--
You received this message because you are subscribed to the Google Groups
"tmux-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [4]tmux-users+unsubscr...@googlegroups.com.
To view this discussion on the web, visit [5]https://groups.google.com/d/msgid/
tmux-users/8159e1aa-964b-4fc5-90c1-4aab87ec9738n%40googlegroups.com.

References:

[1] https://groups.google.com/d/msgid/
[2] http://40googlegroups.com/
[3] 
https://groups.google.com/d/msgid/tmux-users/56375754-89d3-48da-90ea-0355117ef2dfn%40googlegroups.com?utm_medium=email&utm_source=footer
[4] mailto:tmux-users+unsubscr...@googlegroups.com
[5] 
https://groups.google.com/d/msgid/tmux-users/8159e1aa-964b-4fc5-90c1-4aab87ec9738n%40googlegroups.com?utm_medium=email&utm_source=footer

--
You received this message because you are subscribed to the Google Groups 
"tmux-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tmux-users+unsubscr...@googlegroups.com.
To view this discussion on the web, visit 
https://groups.google.com/d/msgid/tmux-users/ZN_t44rGAcaVR3Ep%40ferrum.ceti.

Reply via email to