From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Lute Kamstra Newsgroups: gmane.emacs.help Subject: Re: inserting output of shell-command (was: Major usability issue) Date: 02 Sep 2002 22:33:00 +0200 Organization: CWI, Amsterdam Sender: help-gnu-emacs-admin@gnu.org Message-ID: References: NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1030999472 18294 127.0.0.1 (2 Sep 2002 20:44:32 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 2 Sep 2002 20:44:32 +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 17ly3i-0004kw-00 for ; Mon, 02 Sep 2002 22:44:30 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 17ly5F-0007Ci-00; Mon, 02 Sep 2002 16:46:05 -0400 Original-Path: shelby.stanford.edu!nntp.stanford.edu!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.online.be!bnewspeer00.bru.ops.eu.uu.net!emea.uu.net!surfnet.nl!news.surfnet.nl!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 32 Original-NNTP-Posting-Host: occarina.pna.cwi.nl Original-X-Trace: news.surfnet.nl 1030998780 25624 192.16.184.200 (2 Sep 2002 20:33:00 GMT) Original-X-Complaints-To: usenet@news.surfnet.nl Original-NNTP-Posting-Date: Mon, 2 Sep 2002 20:33:00 +0000 (UTC) User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 In-Reply-To: Original-Xref: nntp.stanford.edu gnu.emacs.help:104406 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:972 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:972 lawrence mitchell writes: > Bruce Korb wrote: > > > For years I have captured the output of a shell command and inserted > > it into my document. The latest distributions of Linux now carry a > > version of emacs that makes doing that non-obvious. I'm sure it is > > doable, but it is really important to just be able to ALT-| then > > type a command and be able to use a mouse click to capture the text. > > I haven't read emacs lisp macros yet in order to reverse-engineer > > what has been done; but I shouldn't have to either. :-( > > /----[ C-h k M-! ] > | M-! runs the command shell-command > | which is an interactive compiled Lisp function in `simple'. > | (shell-command COMMAND &optional OUTPUT-BUFFER ERROR-BUFFER) > | > | Execute string COMMAND in inferior shell; display output, if any. > | With prefix argument, insert the COMMAND's output at point. > | [...] > \---- > > So you probably want to be typing something like C-1 M-! at the > correct point in your buffer. Oops, typo. Make that: C-u M-! Lute. -- (spook) => "genetic Crypto AG White Water" (insert-file-contents "~/.signature") => (error "`~/.signature' too rude")