Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a way to make longlines mode the default for just the *compilation* buffer?

share|improve this question
Just commenting to note that longlines mode will be deprecated in favour of visual-line-mode in the upcoming Emacs 24.4 release. (visual-line-mode was added in version 23.1.) – legoscia Apr 12 '13 at 12:43
Dandy! Any word on plans to make visual-line-mode work properly? – Aaron Miller Apr 17 '13 at 18:53

There sure is; you add to the compilation-mode-hook, which is called any time you enter compilation mode, a function which sets longlines-mode. Add the following to your ~/.emacs, or some other such suitable place:

  (defun compilation-mode-longlines-hook ()
    "Set longlines-mode when entering compilation mode."
    (longlines-mode t))

  (add-hook 'compilation-mode-hook 'compilation-mode-longlines-hook)
share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .