1

I am facing the question about the buffer selected after killing the current buffer.

When I kill the current buffer, the recent file buffer is selected ignoring asterisk buffers. Unless there are no file buffers, an asterisk buffer is not selected. But when I tested on default emacs (invoked by emacs -q), an asterisk buffer can be selected similarly to a file buffer after killing. I want to select asterisk buffers in the same way as file buffers after killing.

I think some packages I installed affect this, so do you have some ideas on what packages stop it from selecting asterisk buffers.

  • You can recursively bisect your init file to determine what package is causing the change. Comment out half of the file, then half of that half, and so on, until you isolate the package in question. It'll probably be a quick process. – Dan Jun 5 '17 at 21:20
  • When you kill a buffer, the function switch-to-prev-buffer is in charge of choosing which buffer to display in the window. It uses the frame paramter buffer-predicate to filter the candidates. The default value is nil, indicating all buffers can be switched to. You can check for the value by evaluting (frame-parameter (selected-frame) 'buffer-predicate) to see if something you have installed changed it. If that's the case, you could use the bug hunter package to bisect your init file and locate the offending line in your configuration. – Omar Jun 6 '17 at 16:31
  • (I think I wasn't clear: my suggestion completely agrees with @Dan's, I was just pointing out a possible way to automate the bisection process.) – Omar Jun 6 '17 at 16:39
  • Thank you very much for your advice! I evaluated (frame-parameter (selected-frame) 'buffer-predicate), and I found spacemacs/useful-buffer-p filtered some asterisk buffers. Putting "" into filtering regexp spacemacs-useless-buffers-regexp solved the problem. – hewld Jun 8 '17 at 16:56
1

Spacemacs caused this problem. spacemacs/useful-buffer-p filtered some asterisk buffers, so putting "" into the filtering regexp spacemacs-useless-buffers-regexp solved this problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.