Can i go to the error after executing make in VIM?

10,564

Solution 1

Yeah this is already buit into vim. After typing :make type :cwindow to bring up the error list. You can then navigate to the errors using this window.

Solution 2

You can as well after :mak or :make do :cope to open the window with compiler output and once you are done :clo to close it.

Use :cn and :cp for jumping to next and previous error or when you are in the window go to line that has the error with file name, line & column and press enter to jump there.

Solution 3

IIRC, this functionality is built into vim. A quick google search revealed this useful link. This describes vim's features for navigating the errors after a make.

Share:
10,564
daisy
Author by

daisy

Updated on June 15, 2022

Comments

  • daisy
    daisy almost 2 years

    Can i go to the line of error , while compiling a C or C++ project ? Usually by executing make , and parse the error string , and go to the specific file , and the line with errors.

    Is there already an usable plugin ?

  • daisy
    daisy over 12 years
    and how can i went through different errors generated by VIM ?
  • Tomasz Gandor
    Tomasz Gandor over 9 years
    :cope - nice one to remember. Although :cwindow abbreviates to shorter :cw. If there were few errors, :cn usually suffices.