This page is no longer maintained — Please continue to the home page at www.scala-lang.org

emacs and sbt shell

2 replies
Erik Engbrecht
Joined: 2008-12-19,
User offline. Last seen 3 years 18 weeks ago.
I have emacs setup according to the instructions here: http://scala.sygneca.com/tools/emacs
After some fiddling it seems to work, except that the colors that sbt uses for its shell are coming across as gibberish text, and as a result links back to where compile errors occurred don't work because the gibberish is treated as part of the file name.
Is there a way to either make emacs handle the colors or turn them off in sbt?
Here's a sample:^[[0m[^[[31merror^[[0m] ^[[0m  foo^[[0m^[[0m[^[[31merror^[[0m] ^[[0m  ^^[[0m ^[[0m[^[[31merror^[[0m] ^[[0mone error found^[[0m^[[0m[^[[0minfo^[[0m] ^[[34m== compile ==^[[0m^[[0m[^[[31merror^[[0m] ^[[0mError running compile: Compilation unsuccessful.^[[0m^[[0m[^[[0minfo^[[0m] ^[[0m^[[0m ^[[0m[^[[0minfo^[[0m] ^[[0mTotal time: 2 s^[[0m

This happens in both Emacs 22.1.1 on the terminal and AquaMacs 1.8.
Thanks,Erik
Florian Hars
Joined: 2008-12-18,
User offline. Last seen 42 years 45 weeks ago.
Re: emacs and sbt shell

Erik Engbrecht schrieb:
> Is there a way to either make emacs handle the colors

(ansi-color-for-comint-mode-on)

> or turn them off in sbt?

java -Dsbt.log.noformat=true -Xmx256M -jar `dirname $0`/sbt-launcher-0.5.2.jar "$@"

HTH, Florian.

Erik Engbrecht
Joined: 2008-12-19,
User offline. Last seen 3 years 18 weeks ago.
Re: emacs and sbt shell
Thanks, I got that from Mark on IRC and Ray Racine off-list.

(ansi-color-for-comint-mode-on) did not work for me.  I wish it did.  It could be the versions of Emacs that I tired.

Turning off formatting in sbt did work.


On Tue, Sep 1, 2009 at 2:41 AM, Florian Hars <hars@bik-gmbh.de> wrote:
Erik Engbrecht schrieb:
> Is there a way to either make emacs handle the colors

(ansi-color-for-comint-mode-on)

> or turn them off in sbt?

java -Dsbt.log.noformat=true -Xmx256M -jar `dirname $0`/sbt-launcher-0.5.2.jar "$@"

HTH, Florian.



--
http://erikengbrecht.blogspot.com/

Copyright © 2012 École Polytechnique Fédérale de Lausanne (EPFL), Lausanne, Switzerland