From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ian Eure Newsgroups: gmane.emacs.help Subject: Re: emacs, shell -- command execution problem Date: Sun, 4 Jan 2009 18:56:47 -0800 Message-ID: References: <055c113b-0b3d-4d49-921a-51598ee8ee05@y1g2000pra.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v930.3) Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1231124249 6823 80.91.229.12 (5 Jan 2009 02:57:29 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 5 Jan 2009 02:57:29 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: relson@osagesoftware.com Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jan 05 03:58:40 2009 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 1LJffn-0004s2-Gj for geh-help-gnu-emacs@m.gmane.org; Mon, 05 Jan 2009 03:58:35 +0100 Original-Received: from localhost ([127.0.0.1]:52266 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LJfeY-0006Wh-7p for geh-help-gnu-emacs@m.gmane.org; Sun, 04 Jan 2009 21:57:18 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LJfeF-0006VP-Mp for help-gnu-emacs@gnu.org; Sun, 04 Jan 2009 21:56:59 -0500 Original-Received: from [199.232.76.173] (port=45553 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LJfeF-0006V3-8G for help-gnu-emacs@gnu.org; Sun, 04 Jan 2009 21:56:59 -0500 Original-Received: from mail.digg.com ([64.191.203.36]:41298) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LJfeE-0003VM-Tc for help-gnu-emacs@gnu.org; Sun, 04 Jan 2009 21:56:59 -0500 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.digg.com (Postfix) with ESMTP id E2147A85014; Sun, 4 Jan 2009 18:56:57 -0800 (PST) X-Virus-Scanned: amavisd-new at X-Spam-Score: 1.124 Original-Received: from mail.digg.com ([127.0.0.1]) by localhost (mail.digg.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id NER8PS2lvoZS; Sun, 4 Jan 2009 18:56:56 -0800 (PST) Original-Received: from [192.168.1.100] (adsl-68-125-160-3.dsl.pltn13.pacbell.net [68.125.160.3]) by mail.digg.com (Postfix) with ESMTP id 101D1A84FE8; Sun, 4 Jan 2009 18:56:53 -0800 (PST) In-Reply-To: <055c113b-0b3d-4d49-921a-51598ee8ee05@y1g2000pra.googlegroups.com> X-Mailer: Apple Mail (2.930.3) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) 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:61066 Archived-At: On Jan 4, 2009, at 3:35 PM, relson@osagesoftware.com wrote: > Within emacs I use the bash shell a lot along with previous line > editing. For example, I might execute a command like: > > ls $( find / -name whatever ) > > then I might use "!!" to recall the above command so I can edit it and > use it again. When I do this, i.e. use "!!", the command is > recalled as > > ls $ ( find / -name whatever ) > > i.e. with 1 blank space between "$" and "(". Presently I have to > manually edit the line to remove the space. Is there a fix for "!!" > that will properly recall the command, i.e. without the blank space? I think you aren't explaining your problem very well. `!!' will not recall the command for editing, but run it again. I ran your command in both Emacs 22 and 23, and it works for me. What doesn't work is running ls $(find place -type f) Then pressing M-p to recall it. This does insert a space between the $(. I don't know why. I suggest that you report the bug to the Emacs maintainers. In the mean time, you can work around it by using: find path -type f -ls Or, you can press C-c C-p, which will move point to the previous command. From there, you can press RET to run it again, or C-c RET to copy it to the current command line. - Ian