Mike's face
Sunday, October 22nd, 2017








vim, java, ant videotapes

Wednesday May 11, 2005 17:43

A vim "errorformat" (efm) setting that makes vim pickup errors output by javac, including the ones where "symbols" are not found.  I couldn't find this anywhere on the internet, so I had to figure it out myself.

It's meant to work for ant build files, which outputs the [javac] lines, but it'll also pickup generic file:line combinations, from grep for instance.

set efm=
\\ %#[javac]\ %#%f:%l:%c:%*\\d:%*\\d:\ %t%[%^:]%#:%m,
\%A\ %#[javac]\ %f:%l:\ %m,
\%-Z\ %#[javac]\ %p^,
\%-C\ %#[javac]\ symbol\ %#:\ %m,
\%-C%.%#,
\%A%f:%l:\ %m,
\%-Z%p^,
\%f:%l

(C) Copyright 2004-2007 Mike Pot