Reputation: 12138
How do I get a list of all buffers in Emacs? I then want to iterate this list using dolist
or mapcar
.
Upvotes: 3
Views: 262
Reputation: 21517
Use (buffer-list &optional frame)
:
Return a list of all existing live buffers. If the optional arg FRAME is a frame, we return the buffer list in the proper order for that frame: the buffers show in FRAME come first, followed by the rest of the buffers.
Upvotes: 6