From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chetan Newsgroups: gmane.emacs.help Subject: Re: redirect stdout to emacs scratch Date: Mon, 08 Dec 2008 07:22:21 -0800 Organization: Noname Inc. Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1228750855 28050 80.91.229.12 (8 Dec 2008 15:40:55 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 8 Dec 2008 15:40:55 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Dec 08 16:42:00 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1L9iF6-0003QB-0s for geh-help-gnu-emacs@m.gmane.org; Mon, 08 Dec 2008 16:41:52 +0100 Original-Received: from localhost ([127.0.0.1]:45530 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L9iDu-00061l-Lf for geh-help-gnu-emacs@m.gmane.org; Mon, 08 Dec 2008 10:40:38 -0500 Original-Path: news.stanford.edu!newsfeed.stanford.edu!headwall.stanford.edu!newshub.sdsu.edu!flph200.ffdc.sbc.com!prodigy.net!flph199.ffdc.sbc.com!prodigy.com!flpi107.ffdc.sbc.com!nlpi065.nbdc.sbc.com.POSTED!8e1d8614!not-for-mail Original-Newsgroups: gnu.emacs.help User-Agent: Emacs Gnus Cancel-Lock: sha1:y2wTNMMbwfl1THFy05kpBjfDPQM= Original-Lines: 36 Original-NNTP-Posting-Host: 75.36.180.162 Original-X-Complaints-To: abuse@prodigy.net Original-X-Trace: nlpi065.nbdc.sbc.com 1228749741 ST000 75.36.180.162 (Mon, 08 Dec 2008 10:22:21 EST) Original-NNTP-Posting-Date: Mon, 08 Dec 2008 10:22:21 EST X-UserInfo1: TSU[@I_AO@RQBQXYWJKB_\XBUSXB@DTMNHWB_EYLJZ]BGIELK^RAQFW[ML\THRCKV^GGZKJMGV^^_JSCFFUA_QXFGVSCYRPILH]TRVKC^LSN@DX_HCAFX__@J\DAJBVMY\ZWZCZLPA^MVH_P@\\EOMW\YSXHG__IJQY_@M[A[[AXQ_XDSTAR]\PG]NVAQUVM Original-Xref: news.stanford.edu gnu.emacs.help:165132 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:60458 Archived-At: pagod writes: > hi everyone! > > this is probably a very easy question (there has to be a way!), but i > haven't been able to find the answer, so i'm turning to this forum, hoping > someone can give me a hint! > > what i want to do is very simple: i want to be able to redirect the stdout > of any program on the command line into emacs' scratch buffer -- the way it > works with less or joe or whatever. i want to do it with emacs because i'm > used to using it and i need syntax coloring, but when i try it i get the > message "standard input is not a tty". then what is it? the way i've tried > it is quite the usual way: > > pagod> echo "hello, world" | emacs > emacs: standard input is not a tty > > my emacs is aliased to "emacs -nw" because i'm in a terminal, so the option > is assumed by default anyway. i'm using the no-window version of emacs > because i run it from within an ssh session running zsh on a linux server, > connecting using putty from a windows workstation. emacs version is 22.2.1, > running in a SuSE 11.0. > > it'd be great if someone could help me do that! > > thx a lot > > David Do you really need to do it this way? You can run it quite simply within the eshell prompt inside emacs. M-x eshell eshell$ echo "foo" >> # eshell$ myprog >> # echell$ echo "bar" >> #