Closed hkjels closed 4 years ago
Emacs has a convention that a buffer not associated with a file will have a name that begins with *
, ie*scratch*
or *Messages*
. So you could try excluding any buffer that begins with *
, and see if you like the result?
OK.. That's what I have, but there's a lot of packages etc that obviously don't follow that convention. Looking for a file-extension would work a lot better I think. I'll scratch this itch in a fork :)
This seems to work pretty well for my use-case. Would you accept a PR? https://github.com/hkjels/dimmer.el/commit/b344659b24926faa30f4448467d9de3b193990ee
Thanks for the PR! Check my comment on the commit... thoughts?
As far as I know you can not negate a regular expression in Emacs, but what I want is to exclude all buffers that are not associated with a file. That could be solved with an inclusion-list I guess or some predicate of linked file.