Tuesday, April 19, 2011

copy text from Vim in PuTTY by highlighting text

copy text from Vim in PuTTY by highlighting text

Method 1:

Holding shift while highlighting.

Method 2:

In ~/.vimrc

" Set mouse equals to nothing stopping vim from interpreting the mouse clicks.
set mouse=

Method 3:

Using Putty ... .to copy whole contains to your clipboard then ... what you do is ...

1. Clear the screen ..
2. Clear the scrollback by right click on the top bar and select the option "clear scrollback".
3. From the same option you will find "change settings" --> select this option and againg select "window" option where specify the huge no. say 99999 in no. line for scrollback where it is 200 by default.

4. Now run the file by using the cat <filename>
5. Right click on the top bar and select the "copy all to clipboard"
6. paste it in the notepad.

Method 4:

you get file in the other way also.

1. You can select the "logging " -> and select the radio button "Log all session output" in Session logging.
2. In the log file name .. specify the log file location by clicking the browse button.
3. Now run the file by cat <filename>.
4. After the file contains end. you can see the the log file which you specified in the log file.

Reference:
https://bbs.archlinux.org/viewtopic.php?id=52862
http://www.unix.com/unix-dummies-questions-answers/31386-copy-text-file-vi-editor-windows-clipboard-2.html

No comments: