Questions tagged [compilation-mode]

Compilation mode turns each error message in the buffer into a hyperlink; you can move point to it and type RET, or click on it with the mouse (see Mouse References), to visit the locus of the error message in a separate window.

78 questions
18
votes
4 answers

Changing the compilation mode current directory automatically?

Currently, my compilation command is as follow: cd ~/somedir && ./somescript.sh This prevents emacs from finding the file in which an error happens (and opening it). Of course I can run M-x cd manually but is there a way to tell the buffer to…
Thomas Moulard
  • 391
  • 3
  • 11
8
votes
1 answer

How can I detect compilation-mode is waiting for input

This often trips me up when building Linux kernels. I'll kick of a compile and after a while I realise it's not completed. What's usually happened is because the default config has changed it's waiting for user input in the compilation window. For…
stsquad
  • 4,651
  • 29
  • 45
5
votes
2 answers

Which regexp from compilation-error-regexp-alist is used by compilation-mode?

I spent a while debugging the regex in compilation-error-regexp-alist only to find that the regex itself is fine. My current theory is that compilation-mode is just actually using a different regex instead. The error message is: ERROR:…
Infiltrator
  • 223
  • 1
  • 4
5
votes
1 answer

How to highlight the compilation buffer?

I try to define a custom coloring of the compilation buffer, but I can not get the highlight correctly. (add-to-list 'compilation-error-regexp-alist 'my-message) (add-to-list 'compilation-error-regexp-alist-alist '(my-message …
ceving
  • 1,358
  • 1
  • 14
  • 28
3
votes
0 answers

show error message on its own line?

I'm using M-x compile to check for compilation errors and it's great. However, I'm wondering if I can get the actual error message to begin on its own line. For some reason the file path shows up as the absolute file path, which is unnecessary IMO…
Jorge Israel Peña
  • 1,265
  • 9
  • 17
2
votes
4 answers

How to see color output when compiling?

Some compilers support color output, which I find helpful when viewing compiler output. GCC for example supports -fdiagnostics-color=always. I would like to build using emacs's compile mode which has the advantage of being able to jump to the…
ideasman42
  • 8,786
  • 1
  • 32
  • 114
2
votes
1 answer

TTY allocation in *Compilation* buffer

I am using some complicated combination of Cygwin (for emacs) and Docker (for Linux environment) for C++ development on my laptop. Recently I noticed that Docker dumps lots of ANSI and XTERM sequences into my *Compilation* buffer. Using redirection…
user26785
  • 161
  • 5
2
votes
2 answers

How to use a separate window for compilation output?

When building, a split view is opened for the output. It's possible to close this window, open a new window and set the buffer to the build output. However when building again, the other window isn't used. Instead a new split is created in the same…
ideasman42
  • 8,786
  • 1
  • 32
  • 114
2
votes
2 answers

Print elapsed time in compilation buffer

The compilation buffer prints out start and end date for my compilation. How can I make it also tell me how many minutes & seconds it spent? I'd like something like: Compilation started at Thu Mar 16 09:10:44 [..] Compilation finished at Thu Mar 16…
skybert
  • 383
  • 4
  • 11
1
vote
2 answers

compilation-mode and next-error confusion

I'm going crazy trying to understand why compilation mode and next-error recognize some errors and not others. It appears as though we're long past the days of simple regexps for recognizing errors but I'm not finding anything that explains what…
kpixley
  • 11
  • 2
1
vote
1 answer

Simultaneously compiling two or more projects with Compilation Mode

I haven't found a way to use Compilation Mode in two projects simultaneously. Starting compilation in a second project kills the compilation of the first. Is it possible to run two compilations simultaneously, perhaps with separate buffers…
Peter Becich
  • 329
  • 1
  • 12
1
vote
1 answer

How to move the point to next link?

Let's say the compilation error has some filenames with line number blah blah src/awesomefile1.c:31 src/awesomefile2.c:152 blah blah Assume the filename are parsed in the buffer and are links. Now my cursor is at the beginning of the buffer. I…
user10375
  • 245
  • 1
  • 6
0
votes
0 answers

OSX: shaking the mouse during compiler output makes it go faster. Why?

I frequently run a Maven job in compilation mode. Maven is very verbose and spews all sorts of stuff to the screen. The build as you might imagine runs for a while. Randomly, while bored and waiting for this job to complete, I happened to notice…
Laird Nelson
  • 101
  • 2
0
votes
1 answer

Overriding the compilation regex to match files and lines for a new tool

How do you get compilation mode to properly detect and underline the file:line pattern of a given tool, to be able to click to directly get to them?
Perdu
  • 51
  • 2
0
votes
0 answers

Reduce false matches of compilations errors

I am running Emacs 28.2. After I recently upgraded from Emacs 27, I started to get a lot of false matches in the compilation buffer. (They may have been there before, but I had to remove my customization of compilation-error-regexp-alist to get…
Troy Daniels
  • 541
  • 3
  • 13
1
2