[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Remove all directory listings buffers

From: Andreas Politz
Subject: Re: Remove all directory listings buffers
Date: Wed, 02 Dec 2009 09:23:17 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux)

"Drew Adams" <address@hidden> writes:

>> >> But I also always end up having too many buffers, I need a better
>> >> strategy for killing them when I don't need them anymore..
>> >
>> > I think some people are in the habit of using `C-x 0' to 
>> > remove the current window, even when they no longer need
>> > the window's buffer.
>> >
>> > I use this as a replacement for `kill-buffer' interactively (only): 
>> No need for a library: C-h f kill-buffer-and-window RET
> Not the same, is it? Take a look at the code.
> If you prefer that, go right ahead and use it.
> * I prefer that it be usable for any buffer, not just the current one 
> (default).
> * I prefer that all of the windows showing the buffer be deleted, not just the
> selected one.
> * I prefer not to have to confirm by typing `y e s RET' instead of `RET'.
> * I prefer that the window not be deleted if `kill-buffer' doesn't kill the
> buffer (e.g. if it was modified and I said not to kill it after all).
> * I prefer that no error be raised if not interactive and the buffer is not
> live. (Yes, I do use this non-interactively also.)
> Don't judge things only by their names. `kill-buffer-and-window' and
> `kill-buffer-and-its-windows' look like they might do the same thing, but what
> counts is the behavior.

kill-buffer-and-window fulfills your initially stated requirements.
This was the basis of my judgement.


> (FWIW, I also use a version of `delete-window' that deletes the frame if has
> only one window, so this same command blows the frame away for me.)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]