all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* How to visit a file and kill the current buffer?
@ 2017-09-10 17:13 Mario Castelán Castro
  2017-09-10 17:24 ` tomas
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Mario Castelán Castro @ 2017-09-10 17:13 UTC (permalink / raw)
  To: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 895 bytes --]

Hello.

Is there a way to visit a file in the current window and at the same
time kill the previous buffer that occupied the current window? I am
looking for something that behaves like the “Open” functionality in
simple GUI text editors (like leafpad).

Very often I have a frame displaying a file, but I no longer need to
have that file open. I wish to instead open another file. What I do
currently is to do C-x C-f and visit the new file, then kill the now
unneeded buffer, but it is annoying to have to do this in 2 steps.
Moreover, I tend to forget the later step and then I accumulate a lot of
“garbage” buffers that are visiting files that I am no longer interested in.

I must note that I use IDO in case it makes any difference.

Thanks.

-- 
Do not eat animals; respect them as you respect people.
https://duckduckgo.com/?q=how+to+(become+OR+eat)+vegan


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2017-09-10 22:13 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.245.1505063646.14750.help-gnu-emacs@gnu.org>
2017-09-10 18:15 ` How to visit a file and kill the current buffer? Marco Wahl
2017-09-10 18:27   ` Mario Castelán Castro
2017-09-10 17:13 Mario Castelán Castro
2017-09-10 17:24 ` tomas
2017-09-10 17:48   ` Mario Castelán Castro
2017-09-10 18:37     ` Emanuel Berg
2017-09-10 19:14       ` tomas
     [not found]       ` <mailman.265.1505070877.14750.help-gnu-emacs@gnu.org>
2017-09-10 22:13         ` Emanuel Berg
2017-09-10 18:01 ` Eli Zaretskii
2017-09-10 18:18   ` Drew Adams
2017-09-10 18:16 ` Drew Adams

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.