X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS X-Spam-Check-By: sourceware.org MIME-Version: 1.0 In-Reply-To: <1d4c5bbf74af4d91aabccf72f841367b@mail.smartmobili.com> References: <1d4c5bbf74af4d91aabccf72f841367b AT mail DOT smartmobili DOT com> Date: Mon, 27 Apr 2009 17:56:28 +0100 Message-ID: <416096c60904270956i12b2a93ci4199b50c4e348745@mail.gmail.com> Subject: Re: mintty and CTRL + -> From: Andy Koppe To: cygwin AT cygwin DOT com Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com 2009/4/27 Vincent R. > on unix terminals when I press CTRL + RIGHT_KEY or CTRL+LEFT_KEY, cursor > move from one word to another > which is very handy. > It doesn't work on mintty and I am sad about it ... ;-) You'll need to configure that behaviour in ~/.inputrc, the config file for the readline library. From the TIPS section of the mintty manual page: Readline configuration Keyboard input for the bash shell and other programs that use the readline library can be configured with the so-called inputrc file. Unless over- ridden by setting the INPUTRC variable, this is located at ~/.inputrc. It consists of bindings of keycodes to readline commands, whereby comments start with a hash character. The file format is explained fully in the bash manual. Anyone used to Windows key combinations for editing text might find the following bindings useful: # Ctrl+Left/Right to move by whole words "\e[1;5D": backward-word "\e[1;5C": forward-word # Ctrl+Backspace/Delete to delete whole words "\d": backward-kill-word "\e[3;5~": kill-word # Ctrl+Shift+Backspace/Delete to delete to start/end of the line "\e\d": backward-kill-line "\e[3;6~": kill-line # Alt-Backspace for undo "\e\b": undo Finally, a couple of bindings for convenient searching of the command his- tory. Just enter the first few characters of a previous command and press Ctrl-Up to look it up. # Ctrl-Up/Down for searching command history "\e[1;5A": history-search-backward "\e[1;5B": history-search-forward > Usually CTRL+d allows me to exit from a terminal when logged in ssh for > instance but it doesn't work either. That should work, unless the end-of-file character is set to something other than ^D on the remote side. Andy -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/