This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: How can I copy and paste into Cygwin console windows?


IVAN_WANG@MAIL.SYNCMOS.com.tw schrieb am 2001-09-10, 18:20:

Hi Ivan,

>     I find this Q&A on http://cygwin.com/fag  .
>
>Then I create  an file .inputrc on ~/.inputrc and add one line as follow
>
>"\e[2~": paste-from-clipboard
>
>Then, I restart cygwin. But it does not work.

Isn't it enough to source the file?
$ souce ~/.inputrc

>I use bind key " Contrl C" on Win2k App. and " Contrl V" on cygwin console
>windows?
>
>How can I do?
>By the way, where I can find document about .inputrc ?

I don't know where to find a proper .inputrc document.
Try a google search around the web?
APROPOS GOOGLE: Has anyone tried the google toolbar yet? 
It is a great feature!  Never call google home again, just
type in the search pattern and 'schwupps' you are there.

Find an answer in the Cygwin FAQ?
=================================
How can I copy and paste into Cygwin console windows?
-----------------------------------------------------

   Under Windows NT, open the properties dialog of the console window.
The options contain a toggle button, named "Quick edit mode".  It must
be ON.  Save the properties.

   Under Windows 9x, open the properties dialog of the console window.
Select the Misc tab.  Uncheck Fast Pasting.  Check QuickEdit.

   You can also bind the insert key to paste from the clipboard by
adding the following line to your .inputrc file:
     	"\e[2~": paste-from-clipboard
[...]


My ~/.inputrc:
==============
# ~/.inputrc
# This file is read by the 'readline' library
# (the library which bash uses for its command-
# line editing facility)

# Make Home work
"\e[1~": beginning-of-line
# Make End work
"\e[4~": end-of-line
# Make Delete work
"\e[3~": delete-char
# Make Insert work
"\e[2~": paste-from-clipboard

# Ignore case for the command-line-completion
# functionality.
#set completion-ignore-case On

set meta-flag On
set convert-meta Off
set output-meta On

# END of .inputrc

The other point is:
If you copy s.th. to clipboard form windows gui application, I always use
'insert' key to paste it on the shell (only with this .inputrc).

The second is /dev/clipboard:
If there is some content in the clipboard, just do: 
$ cat /dev/clipboard [ > somewhere ] [ >>somewhere ]
If you want to copy to the clipboard do: 
$ cat file.txt [ >/dev/clipboard | >>/dev/clipboard ]
$ echo Hello > /dev/clipboard

Third possibility is to use the mouse:
Check the boxes in the settings tab of the shortcut:
"QuickEdit Mode" [ and "InsertMode" ] (or in the settings at the 
top-left-window pull-down-menu).

In 'rxvt' it is possible to use the mouse very easy, double click marks
a full word, three clicks the whole line. If it is marked, it is in the 
clipboard. Paste it in rxvt with <shift>-left-click.
Elsewhere with 'Insert' or use the mouse.
Actually I like the rxvt way you can mark with the mouse as in other 
windows applications plus the handy <shift>-left-click.

Gerrit


-- 
=^..^=

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]