emacs terminal mode: how to copy and paste efficiently

前端 未结 2 1464
臣服心动
臣服心动 2021-02-13 21:09

I\'m having a hard time making this emacs -nw work effectively under the terminal mode (emacs -nw). Some setup information: The working server is connected via SSH, and emacs i

2条回答
  •  囚心锁ツ
    2021-02-13 22:04

    This is not an ideal solution per se, but i figured out a way that I feel better than the previous one.

    The idea is to get rid of X which causes heavy latency issues, i.e. keep only the following:

    ;; enable clipboard in emacs
    (setq x-select-enable-clipboard t)
    

    The results are:

    1. copy/paste within Emacs is straightforward and fast.

    2. copy from other apps to Emacs: Ctrl+Shift+v

    3. copy from Emacs to other apps: mouse selection is now on X Selection, so right-click and copy shall copy the text into the Selection. Note that 'M-w" now won't copy anything into Selection or system clipboard.

    This is again a compromise rather than a solution, but considering the fact that i copy/paste more often than inter-app operations, this is acceptable at the moment.

    Still looking forward to a good solution!

提交回复
热议问题