Path: utzoo!utgpu!watmath!att!pacbell!ames!mailrus!tut.cis.ohio-state.edu!ucbvax!hplabs!hp-sdd!megatek!zeta!hollen From: hollen@zeta.megatek.uucp (Dion Hollenbeck) Newsgroups: comp.emacs Subject: Re: Buffer-menu kill all files? Message-ID: <669@megatek.UUCP> Date: 7 Aug 89 17:53:43 GMT References: <624@mipos3.intel.com> Sender: news@megatek.UUCP Lines: 44 From article <624@mipos3.intel.com>, by nate@hobbes.intel.com (Nate Hess): > In article <668@megatek.UUCP>, hollen@zeta (Dion Hollenbeck) writes: >>is there a way to mark ALL files for deletion with one command? > > With the cursor on the first buffer in the list, type 99d > > --woodstock Thanks for the valiant try, but no cigar. Buffer-menu-mode and the attendant sparse keymap do not allow numbers and every press of '9' elicits a beep from the keyboard. I have added some code to buff-menu.el, but I cannot get the key to map which would execute it. Maybe someone could help. Here is the code: ADDED THE FOLLOWING LINE TO THE KEYMAP DEFINITION: (define-key Buffer-menu-mode-map "a" 'Buffer-menu-mark-all-delete) ADDED THE FOLLOWING FUNCTION DEFINITION: (defun Buffer-menu-mark-all-delete () "Mark all buffers to be deleted by \\[Buffer-menu-execute] command and move to the end of the buffer menu." (interactive) (goto-char (point-min)) (while (looking-at " [-M]") (forward-line 1)) (while (looking-at "[ .]") (Buffer-menu-delete) (forward-line 1) ) ) ADDED THE FOLLOWING TO MY .EMACS FILE SO THAT MY BUFFER MENU DEFINITIONS WOULD BE USED INSTEAD OF THE USUAL ONES. IS MY BUFF-MENU KEYMAP BEING DEFINED FIRST AND THE STANDARD ONE RE-DEFINING IT? (load "/usr2/hollen/Emacs/buff-menu.el") Dion Hollenbeck (619) 455-5590 x2814 Megatek Corporation, 9645 Scranton Road, San Diego, CA 92121 uunet!megatek!hollen or hollen@megatek.uucp