From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.devel Subject: Re: Change in emacsclient behavior Date: Fri, 07 Sep 2007 09:06:28 +0200 Message-ID: <851wdb7y4r.fsf@lola.goethe.zz> References: <87veaw5ds5.fsf@baldur.tsdh.de> <87veatxcrz.fsf@jurta.org> <59272.128.165.123.18.1188947304.squirrel@webmail.lanl.gov> <85hcm8hmwi.fsf@lola.goethe.zz> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: sea.gmane.org 1189148816 14976 80.91.229.12 (7 Sep 2007 07:06:56 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 7 Sep 2007 07:06:56 +0000 (UTC) Cc: juri@jurta.org, emacs-devel@gnu.org To: rms@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Sep 07 09:06:54 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1ITXvT-0001dp-Qj for ged-emacs-devel@m.gmane.org; Fri, 07 Sep 2007 09:06:48 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ITXvR-00016I-UX for ged-emacs-devel@m.gmane.org; Fri, 07 Sep 2007 03:06:45 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1ITXvP-00016B-2t for emacs-devel@gnu.org; Fri, 07 Sep 2007 03:06:43 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1ITXvN-00015x-JN for emacs-devel@gnu.org; Fri, 07 Sep 2007 03:06:41 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ITXvN-00015u-E3 for emacs-devel@gnu.org; Fri, 07 Sep 2007 03:06:41 -0400 Original-Received: from mx20.gnu.org ([199.232.41.8]) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1ITXvH-0005pz-6I; Fri, 07 Sep 2007 03:06:35 -0400 Original-Received: from mail-in-08.arcor-online.net ([151.189.21.48]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1ITXvG-0003sF-H5; Fri, 07 Sep 2007 03:06:34 -0400 Original-Received: from mail-in-08-z2.arcor-online.net (mail-in-08-z2.arcor-online.net [151.189.8.20]) by mail-in-08.arcor-online.net (Postfix) with ESMTP id 7218927ADEE; Fri, 7 Sep 2007 09:06:29 +0200 (CEST) Original-Received: from mail-in-10.arcor-online.net (mail-in-10.arcor-online.net [151.189.21.50]) by mail-in-08-z2.arcor-online.net (Postfix) with ESMTP id 62E68212FA9; Fri, 7 Sep 2007 09:06:29 +0200 (CEST) Original-Received: from lola.goethe.zz (dslb-084-061-044-151.pools.arcor-ip.net [84.61.44.151]) by mail-in-10.arcor-online.net (Postfix) with ESMTP id 24A1D2351A8; Fri, 7 Sep 2007 09:06:29 +0200 (CEST) Original-Received: by lola.goethe.zz (Postfix, from userid 1002) id C25A21CAD71B; Fri, 7 Sep 2007 09:06:28 +0200 (CEST) In-Reply-To: (Richard Stallman's message of "Fri\, 07 Sep 2007 02\:30\:38 -0400") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1.50 (gnu/linux) X-Virus-Scanned: ClamAV 0.91.2/4175/Thu Sep 6 22:16:54 2007 on mail-in-10.arcor-online.net X-Virus-Status: Clean X-detected-kernel: Linux 2.4-2.6 X-Detected-Kernel: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:78100 Archived-At: --=-=-= Richard Stallman writes: > > 5. Become a pipe for Emacs (which may or may not produce > > any terminal output). > > > > These all seem useful in principle. 5 seems hard and I doubt > > it is worth implementing. > > It would make it possible to configure an Emacsclient invocation > as a $PAGER command. > > Sorry, I do not follow. Executables like "man" use a pager configurable in $PAGER for their output. Calling man in an Emacs shell session creates a lot of garbage due to terminal problems. It would be much nicer if one could configure something into $PAGER which just sucked up its stdin and made it available in a separate Emacs buffer in view mode. In fact, I _have_ something like that configured as a pager, namely the following executable: --=-=-= Content-Type: text/x-sh Content-Disposition: inline; filename=emacs-pager #!/bin/sh TMP=`mktemp -t emacs-pager.XXXXXX` trap "rm $TMP* 2>/dev/null" 0 echo '-*- mode: view; auto-revert-interval: 1; mode: auto-revert-tail; view-exit-action: kill-buffer -*-' >"$TMP" exec 5<&0 <&- cat "$@" <&5 >>"$TMP" & eval "${VISUAL:-${EDITOR}}" '"$TMP"' --=-=-= Now this has several drawbacks: it takes a longer startup time, it needs a temporary file, and it does not stop the data generating process when the material will not get read to its end, anyway. For example (a useless example, agreed), yes|$PAGER works well with $PAGER being less and/or more, but redirecting to a temporary file is not so great. -- David Kastrup, Kriemhildstr. 15, 44793 Bochum --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel --=-=-=--