From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: kai.grossjohann@uni-duisburg.de (Kai =?iso-8859-1?q?Gro=DFjohann?=) Newsgroups: gmane.emacs.help Subject: Re: shell-mode autocompletion uglinesses Date: Mon, 02 Dec 2002 21:20:34 +0100 Organization: University of Dortmund, Germany Sender: help-gnu-emacs-admin@gnu.org Message-ID: <84y978cgvh.fsf@lucy.cs.uni-dortmund.de> References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1038860891 23954 80.91.224.249 (2 Dec 2002 20:28:11 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 2 Dec 2002 20:28:11 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18IxAl-0006Dt-00 for ; Mon, 02 Dec 2002 21:28:07 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18Ix8o-0001Ap-00; Mon, 02 Dec 2002 15:26:06 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!logbridge.uoregon.edu!fu-berlin.de!uni-berlin.de!pd951f339.dip.t-dialin.NET!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 48 Original-NNTP-Posting-Host: pd951f339.dip.t-dialin.net (217.81.243.57) Original-X-Trace: fu-berlin.de 1038860434 27837894 217.81.243.57 (16 [73968]) User-Agent: Gnus/5.090008 (Oort Gnus v0.08) Emacs/21.3.50 (i686-pc-linux-gnu) Cancel-Lock: sha1:cTkh4WgTjvgSFNdyqELrXf3LHHk= Original-Xref: shelby.stanford.edu gnu.emacs.help:107666 Original-To: help-gnu-emacs@gnu.org Errors-To: help-gnu-emacs-admin@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.help:4216 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:4216 "Felix E. Klee" writes: > there are two things that bother me enormously when using autocompletion in > shell-mode. > 1. When I enter > ls /usr/ > and press tab nothing happens. What I expect, however, is that I get a > list of choices containing all files and directories in "/usr/". What happens if you press TAB again? > 2. Suppose my EMACS window is split horizontally with a shell in one buffer > and a README giving me instructions in another buffer. When I enter > ls /usr/in > I see the following list in the *Completions* buffer: > include/ info/ > Then I press "n tab" and the shell command expands into > ls /usr/include > as intended. Now, however, the *Completions* buffer is still there > although it is not needed anymore. How do I make it go away once I have > finished my completion? I think pcomplete has a mechanism for making the completions buffer disappear. At least I know that eshell does this. Maybe Emacs will use pcomplete completion by default in the future. > If I cannot change the above behavior I'd rather use tab autocompletion as > implemented in my shell (BASH). Is this possible? Once upon a time, there was a file which purported to use the tcsh tab completion in shell mode. It was years ago. Maybe it also works for bash. I have no idea how to find the file. It had `tcsh' in its name and possibly also `complet'. Another alternative would be to set up shell mode to use pcomplete now. Hm. Ah! Maybe it's sufficient to (require 'shell) (define-key shell-mode-map (kbd "TAB") 'pcomplete) How about you try this? pcomplete completion is programmable. It groks `make' (completes on targets from Makefile) by default. -- ~/.signature is: umop ap!sdn (Frank Nobis)