From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.help Subject: RE: Extend Dired to Call a Function on a File? Date: Wed, 12 Oct 2016 17:34:04 -0700 (PDT) Message-ID: <84855d7f-160b-4886-bede-45d2dea066b1@default> References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1476318913 31288 195.159.176.226 (13 Oct 2016 00:35:13 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 13 Oct 2016 00:35:13 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Brendan Leber Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Oct 13 02:35:09 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1buTyx-0004mY-EH for geh-help-gnu-emacs@m.gmane.org; Thu, 13 Oct 2016 02:34:47 +0200 Original-Received: from localhost ([::1]:36608 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1buTyv-0000En-3S for geh-help-gnu-emacs@m.gmane.org; Wed, 12 Oct 2016 20:34:45 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48690) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1buTyU-0000EV-Jp for help-gnu-emacs@gnu.org; Wed, 12 Oct 2016 20:34:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1buTyQ-0007Sn-Dc for help-gnu-emacs@gnu.org; Wed, 12 Oct 2016 20:34:17 -0400 Original-Received: from aserp1040.oracle.com ([141.146.126.69]:23472) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1buTyQ-0007Qr-86 for help-gnu-emacs@gnu.org; Wed, 12 Oct 2016 20:34:14 -0400 Original-Received: from aserv0021.oracle.com (aserv0021.oracle.com [141.146.126.233]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id u9D0Y8qb009572 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 13 Oct 2016 00:34:09 GMT Original-Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserv0021.oracle.com (8.13.8/8.13.8) with ESMTP id u9D0Y8KU016465 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 13 Oct 2016 00:34:08 GMT Original-Received: from abhmp0009.oracle.com (abhmp0009.oracle.com [141.146.116.15]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id u9D0Y7f6015063; Thu, 13 Oct 2016 00:34:07 GMT In-Reply-To: X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 12.0.6753.5000 (x86)] X-Source-IP: aserv0021.oracle.com [141.146.126.233] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 141.146.126.69 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:111520 Archived-At: > > But I guess you are asking about mapping a Lisp function over files. >=20 > That is what I meant. >=20 > > If you are asking about Dired then presumably you are talking about > > acting on the marked files (else, why Dired?). If so, and if you > > use Dired+, then you can use `@', which is bound to command > > `diredp-do-apply-function', to apply a Lisp function to each of the > > marked files. >=20 > I haven't used Dired+ but it sounds like the `@' key will do exactly > what I want. Thanks! Also, if you don't care about using Dired, and you just want to act on all of the files in a directory that match a regexp, you can just map your function over the result of calling `directory-files'.