Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When I use make into vim, with :make it automatically jump to the first error, displaying a new buffer in the current tab if needed.

I use vim with multiple tabs, most of the time the error buffer is already opened in another tab. Because of that, using :tabn or :tabp doesn't work in my case. :b# either... And the previous buffer could be the non last edited one.

share|improve this question
up vote 1 down vote accepted

There are two ways to address this:

  1. Use :make! and vim won't switch the buffer in the first place.
  2. Set switchbuf to useopen,usetab and the implicit :cf will attempt to switch to an existing window or tab displaying the buffer.
share|improve this answer
switchbuf=usetab is exactly what I wanted, thanks! – Jérôme Jan 4 '12 at 16:23

You can try CTRL-o.

I use CTRL-z before make, then fg bring vim back.

share|improve this answer
I am using make inside vim – Jérôme Jan 4 '12 at 15:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .