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: need for a shell-mode-post-hook ? Date: Tue, 11 Mar 2003 16:31:34 +0100 Organization: University of Duisburg, Germany Sender: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: <84d6kxkjhl.fsf@lucy.is.informatik.uni-duisburg.de> References: <87smu22ncd.fsf@killr.ath.cx> <5l65qrnfa3.fsf@rum.cs.yale.edu> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1047397180 26776 80.91.224.249 (11 Mar 2003 15:39:40 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Tue, 11 Mar 2003 15:39:40 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Tue Mar 11 16:39:39 2003 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 18slqM-0006vJ-00 for ; Tue, 11 Mar 2003 16:39: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 18slna-0004Km-0D for gnu-help-gnu-emacs@m.gmane.org; Tue, 11 Mar 2003 10:36:15 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!headwall.stanford.edu!fu-berlin.de!uni-berlin.de!pd951fdcc.dip.t-dialin.NET!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 25 Original-NNTP-Posting-Host: pd951fdcc.dip.t-dialin.net (217.81.253.204) Original-X-Trace: fu-berlin.de 1047396707 67469512 217.81.253.204 (16 [73968]) User-Agent: Gnus/5.090016 (Oort Gnus v0.16) Emacs/21.3.50 (gnu/linux) Cancel-Lock: sha1:Hx26I8JG5buC58/Xd9k+APKRbtU= Original-Xref: shelby.stanford.edu gnu.emacs.help:110981 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:7482 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:7482 "Stefan Monnier" writes: >>>>>> "Matthew" == Matthew Kennedy writes: >> (add-hook 'shell-mode-post-hook '(erase-buffer)) > > That's difficult because the shell buffer is asynchronous, so > Emacs doesn't know when the shell's initialization is done. > > Tramp has to deal with the problem and it's pretty ugly, but maybe > you can convince Kai to tell you how to reuse that ugly code for > this other case ? Tramp just looks for a shell prompt... But maybe Matthew could change his ~/.emacs_bash to produce less output? For example, maybe it works to put all commands on one (virtual) line by doing things like command1; \ command2; \ ... in ~/.emacs_bash. -- A preposition is not a good thing to end a sentence with.