From: Laird Nelson <ljnelson@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Upgraded to Emacs 24; custom compilation-error-regexp-alist no longer works
Date: Wed, 16 Jan 2013 16:58:10 -0800 [thread overview]
Message-ID: <CAHNdxumw7_+3siANrA4f7xQXrw5u-7FG7jfrviX6Hedpa_1w_A@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1872 bytes --]
Hello; I hope this is the right email list for this kind of question.
I just upgraded to Emacs 24.2 on a Mac. I'm using the no-nonsense prefab
distribution of Emacs.app.
I have customized my compilation-error-regexp-alist to handle Maven 3.0.4
output (well, or more specifically to handle the output of the
maven-compiler-plugin version 3.0). However, it does not identify error
output properly, even though re-builder shows the regexp as matching just
fine.
Here is some sample output from the compiler:
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR]
/Users/ljnelson/Projects/github/foobar/src/main/java/foobar/BasicThreadScheduler.java:[42,12]
cannot find symbol
symbol : constructor
Thread(foobar.ProgramCounter<T>,java.util.List<T>,int,foobar.BasicThreadScheduler<T>)
location: class foobar.Thread<T>
Using re-builder, I found that the following regular expression matches the
relevant line above, with a total of three capture groups (not including
group 0, i.e. the whole string):
^\\[\\(?:ERROR\\|WARNING\\)\\]\s+\\([^[]+\\):\\[\\([0-9]+\\),\\([0-9]+\\)\\]
Using the customize emacs machinery, I added this to
compilation-error-regexp-alist as an error specification:
("
^\\[\\(?:ERROR\\|WARNING\\)\\]\s+\\([^[]+\\):\\[\\([0-9]+\\),\\([0-9]+\\)\\]"
1 2 3)
My intent was that the first of three capture groups should identify the
filename, the second the line number, and the third the column number. In
my sample output above, re-builder shows that the following line is the
first line matched:
[ERROR]
/Users/ljnelson/Projects/github/foobar/src/main/java/foobar/BasicThreadScheduler.java:[42,12]
cannot find symbol
However, my compilation buffer does not "light up" like it used to.
What am I missing?
Thanks for any help you can provide.
Best,
Laird
--
http://about.me/lairdnelson
[-- Attachment #2: Type: text/html, Size: 3730 bytes --]
next reply other threads:[~2013-01-17 0:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-17 0:58 Laird Nelson [this message]
2013-01-17 1:26 ` Upgraded to Emacs 24; custom compilation-error-regexp-alist no longer works Laird Nelson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAHNdxumw7_+3siANrA4f7xQXrw5u-7FG7jfrviX6Hedpa_1w_A@mail.gmail.com \
--to=ljnelson@gmail.com \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).