Ok so this question is vaguely related to one of my previous questions:
I want Vim to be able to save and close similarly to Photoshop in regards to buffers?
Basically the solution I found (or gets really close to what I want), is a plugin called BufOnly which basically closes all buffers that have not been modified. So when I have a lot of buffers open and I want to close, I just run this, and then just care of everything that I haven't already. It works well.
But I'm greedy. I want this to execute automatically when I need it to. Basically I would like it so that if I run qa, if qa runs into -->
E73: No write since list change (add ! to override)
Then I want to run
:BufOnly<CR>:bd <cr>
Is there a way to do that?