Last active
August 29, 2015 14:10
-
-
Save kkrull/72bca73f33e3b74a5165 to your computer and use it in GitHub Desktop.
Figured out how to run the Scala REPL under Cygwin/tmux in Windows.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Getting the Scala REPL to work on Cygwin | |
There are some [nuances](https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=2&cad=rja&uact=8&sqi=2&ved=0CCQQFjAB&url=https%3A%2F%2Fwww.java.net%2Fblog%2Fcayhorstmann%2Farchive%2F2010%2F11%2F24%2Freport-sewer-hole-cygwin-jline-rxvt-and-scala-repl&ei=JKh0VLfQBISkyQSi_4CgDg&usg=AFQjCNEnrpRtLU8SZGXW9K11_KTPfBkzWA&sig2=0FHjPkgXNe0h9abfwZNo0w) to getting the Scala REPL working in Cygwin. | |
If you install version 2.11.4 for Windows, `/Applications32/scala/bin/scala` already attempts to follow these instructions. If you're running under MinGW with `TERM=xterm-256color`, it works. However when you start tmux or screen, it often changes the value of `TERM`. You can get around this by: | |
TERM=xterm-256color /Applications32/scala/bin/scala | |
It may be more convenient to drop this in a script, such as `$HOME/bin/scala` | |
``` | |
#!/bin/bash | |
#Set TERM so that scala's script realizes we're in a cygwin environment, even under tmux (Which sets TERM to `screen`). | |
TERM=xterm-256color; SCALA_RUNNER_DEBUG=true /Applications32/scala/bin/scala | |
``` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment