From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.help Subject: RE: Dired narrowing? Date: Sun, 3 Oct 2004 10:51:18 -0700 Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: References: 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 1096825934 32065 80.91.229.6 (3 Oct 2004 17:52:14 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 3 Oct 2004 17:52:14 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Oct 03 19:52:06 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 1CEAWj-0004VU-00 for ; Sun, 03 Oct 2004 19:52:06 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CEAdH-0003nb-UB for geh-help-gnu-emacs@m.gmane.org; Sun, 03 Oct 2004 13:58:51 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CEAdA-0003nE-5e for help-gnu-emacs@gnu.org; Sun, 03 Oct 2004 13:58:44 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CEAd9-0003n2-PL for help-gnu-emacs@gnu.org; Sun, 03 Oct 2004 13:58:43 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CEAd9-0003mz-ME for help-gnu-emacs@gnu.org; Sun, 03 Oct 2004 13:58:43 -0400 Original-Received: from [141.146.126.229] (helo=agminet02.oracle.com) by monty-python.gnu.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.34) id 1CEAW8-0007UV-N5 for help-gnu-emacs@gnu.org; Sun, 03 Oct 2004 13:51:28 -0400 Original-Received: from rgmgw1.us.oracle.com (rgmgw1.us.oracle.com [138.1.191.10]) by agminet02.oracle.com (Switch-3.1.4/Switch-3.1.0) with ESMTP id i93HpRSu032408; Sun, 3 Oct 2004 10:51:27 -0700 Original-Received: from rgmgw1.us.oracle.com (localhost [127.0.0.1]) by rgmgw1.us.oracle.com (Switch-3.1.4/Switch-3.1.0) with ESMTP id i93HpQlQ002891; Sun, 3 Oct 2004 11:51:26 -0600 Original-Received: from dradamslap (dhcp-amer-csvpn-gw1-141-144-65-21.vpn.oracle.com [141.144.65.21]) by rgmgw1.us.oracle.com (Switch-3.1.4/Switch-3.1.0) with SMTP id i93HpQ9b002880; Sun, 3 Oct 2004 11:51:26 -0600 Original-To: "Bill White" , X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441 In-Reply-To: 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: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:21031 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:21031 Shortcut: Command dired-mark-extension is bound to `* .'. Use it to mark all files with a particular extension (such as txt). - Drew -----Original Message----- From: Bill White On Sun Oct 03 2004 at 01:22, bgm-rao@ieee.org said: > How do I narrow a dired buffer to see only files with a regexp name? I someone has a shorter sequence for this, please post it. I use a three-command sequence: '% m' to mark the files you want. To mark .txt files, the regexp would be "\.txt" or perhaps "\.txt$" (without the quotes). ^ matches the beginning of a file name, not the beginning of a dired line. To mark temp* you might do "^temp". 't' to invert the marks, so the ones you *don't* want are marked. 'k' to kill the marked lines (this doesn't delete files, it just removes listings temporarily from the dired listing). ---------------------------------------------------------------------- '% m' is dired-mark-files-regexp ,----[ C-h f dired-mark-files-regexp RET ] | dired-mark-files-regexp is an interactive compiled Lisp function in `dired'. | (dired-mark-files-regexp REGEXP &optional MARKER-CHAR) | | Mark all files matching REGEXP for use in later commands. | A prefix argument means to unmark them instead. | `.' and `..' are never marked. | | REGEXP is an Emacs regexp, not a shell wildcard. Thus, use `\.o$' for | object files--just `.o' will mark more than you might think. `---- 't' is dired-toggle-marks ,----[ C-h f dired-toggle-marks RET ] | dired-toggle-marks is an interactive compiled Lisp function in `dired'. | (dired-toggle-marks) | | Toggle marks: marked files become unmarked, and vice versa. | Files marked with other flags (such as `D') are not affected. | `.' and `..' are never toggled. | As always, hidden subdirs are not affected. `---- 'k' is dired-do-kill-lines ,----[ C-h f dired-do-kill-lines RET ] | dired-do-kill-lines is an interactive compiled Lisp function in `dired-aux'. | (dired-do-kill-lines &optional ARG FMT) | | Kill all marked lines (not the files). | With a prefix argument, kill that many lines starting with the current line. | (A negative argument kills backward.) | If you use this command with a prefix argument to kill the line | for a file that is a directory, which you have inserted in the | Dired buffer as a subdirectory, then it deletes that subdirectory | from the buffer as well. | To kill an entire subdirectory (without killing its line in the | parent directory), go to its directory header line and use this | command with a prefix argument (the value does not matter). `----