On Wed, Jul 14, 2010 at 02:56:33PM +0100, Wayne Fay wrote: > > is it possiible to change the format of error messages to that which the > > standalone javac compiler produces? I haven't found anything on that in > > the compiler:compile at maven.apache.org. > > If you can find a way to do this with plain old Javac from the command > line, then you can probably make it work in Maven. > > What is the command line equivalent "javac .... blah.java" that you > want to utilize?
the background of my question is that I'd like emacs to be able of jumping to the source that caused the error. That has stopped working for me since switching to Maven. However, I've now managed to restorE that to a reasonable extent (I hope) by adding an additional regular expression to the list that emacs uses for parsing compilation errors by adding (setq compilation-error-regexp-alist (cons '("^\\(\\[WARNING\\] \\)?\\(/[^:]+\\):\\[\\([0-9]+\\),\\([0-9]+\\)\\]" 2 3 4) compilation-error-regexp-alist)) to my ~/.emacs startup file. The maven compilation error messages don't contain any constant text that one could easily use for matching with a regular expression, my regexp above just relies on error messages starting with a forward slash (as part of the absolute path to the source file) and that the line number is separated from the file name by ":[". So as a thought, perhaps a future version of maven could change the format to contain a fixed, regexp-friendly string -- or perhaps error message formats could become configurable via pom settings. Best regards, Jan -- +- Jan T. Kim -------------------------------------------------------+ | email: j....@uea.ac.uk | | WWW: http://www.cmp.uea.ac.uk/people/jtk | *-----=< hierarchical systems are for files, not for humans >=-----* --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org