From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Reinhard Kotucha Newsgroups: gmane.emacs.devel Subject: Re: ! in Dired--what was the outcome? Date: Fri, 15 Oct 2004 01:30:25 +0200 Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Message-ID: <16751.3089.79455.136342@zarniwoop.ms25.local> References: <87vfdgezro.fsf@jurta.org> <200410130301.i9D31GM02856@raven.dms.auburn.edu> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1097797178 13928 80.91.229.6 (14 Oct 2004 23:39:38 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 14 Oct 2004 23:39:38 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Oct 15 01:39:27 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CIFBu-0001Qy-00 for ; Fri, 15 Oct 2004 01:39:26 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CIFJ1-0003ND-Ps for ged-emacs-devel@m.gmane.org; Thu, 14 Oct 2004 19:46:47 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CIFIo-0003ML-Dc for emacs-devel@gnu.org; Thu, 14 Oct 2004 19:46:34 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CIFIn-0003Lp-Bi for emacs-devel@gnu.org; Thu, 14 Oct 2004 19:46:33 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CIFIn-0003LF-3K for emacs-devel@gnu.org; Thu, 14 Oct 2004 19:46:33 -0400 Original-Received: from [199.232.41.8] (helo=mx20.gnu.org) by monty-python.gnu.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.34) id 1CIFBB-000641-7n for emacs-devel@gnu.org; Thu, 14 Oct 2004 19:38:41 -0400 Original-Received: from [217.72.192.209] (helo=smtp05.web.de) by mx20.gnu.org with esmtp (Exim 4.34) id 1CIF4M-0002pf-Tr for emacs-devel@gnu.org; Thu, 14 Oct 2004 19:31:39 -0400 Original-Received: from [82.82.155.238] (helo=zarniwoop.ms25.local) by smtp05.web.de with esmtp (TLSv1:DES-CBC3-SHA:168) (WEB.DE 4.101 #44) id 1CIF3D-00029A-00; Fri, 15 Oct 2004 01:30:27 +0200 Original-Received: from zarniwoop.ms25.local (reinhard@localhost [127.0.0.1]) by zarniwoop.ms25.local (8.12.9/8.12.9) with ESMTP id i9ENUPik007779; Fri, 15 Oct 2004 01:30:26 +0200 Original-To: Johan Vromans In-Reply-To: X-Mailer: VM 7.18 under Emacs 21.3.50.2 X-Sender: reinhard.kotucha@web.de 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: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:28396 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:28396 >>>>> "Johan" == Johan Vromans writes: > Likewise, {} could be made available to 'shell-command' as well, > to make it easy to run arbitrary commands on the file associated > with the current buffer. For example C-x C-s M-! cp {} {}.save > RET before starting to make possibly hazardous changes... The example is quite special. It allows to append an extension, but it disallows to remove one. What I do very often in bash is for file in *.ps ; do convert $file ${file%%ps}pdf done Maybe your syntax can be extended, for instance like this: convert {} {/ps$//}pdf or convert {} {/ps$/pdf/} Using regexps is much more powerful than the substring approach in bash anyway. Regards, Reinhard -- ---------------------------------------------------------------------------- Reinhard Kotucha Phone: +49-511-4592165 Marschnerstr. 25 D-30167 Hannover mailto:reinhard.kotucha@web.de ---------------------------------------------------------------------------- Microsoft isn't the answer. Microsoft is the question, and the answer is NO. ----------------------------------------------------------------------------