hvesalai / emacs-sbt-mode

An emacs mode for interacting with scala sbt and projects
GNU General Public License v3.0
125 stars 38 forks source link

broken on Windows #33

Closed fommil closed 8 years ago

fommil commented 9 years ago

I set up a virtualbox image to test out my dev environment on Windows and I was unable to use sbt-mode, it just froze up emacs. sbt works fine from the command line. I'll see if I can zip up my virtual box image and share it with you.

fommil commented 8 years ago

I can now confirm that sbt-command does not work on Windows 7. Sending any command to the sbt buffer results in the screen being cleared and no output being shown.

Typing commands manually into the sbt buffer appear to just be ignored, with no clearing of the screen and no output shown.

In both cases, I did not see any files produced on disk as the result of the sbt operation that I wanted to perform, so I am led to believe that sbt-mode simply ignores input when running on Windows :cry:

@edani don't you use Windows in your setup? Does sbt-mode work for you?

fommil commented 8 years ago

btw if I enable debug-on-quit and then C-g when running a command, this is the stacktrace:

Debugger entered--Lisp error: (quit)
  accept-process-output(#<process *sbt*<d:/myproject/src/>>)
  comint-send-input()
  call-interactively(comint-send-input nil nil)
  command-execute(comint-send-input)
fommil commented 8 years ago

If you could write a test for sbt-command I could probably wire it up to AppVeyor and get Windows testing as part of CI to save you from having to set up a windows dev environment.

edani commented 8 years ago

@fommil Checking out the WinXP virtualbox you set up is still on my list. As far as sbt-mode, it works for me (Win 8). Note that I use native emacs, not Cygwin, so sbt-mode executes the sbt.bat that it finds on my PATH. I do notice display problems when running sbt from a cygwin console, so that may be related.

fommil commented 8 years ago

hmm, I'm also running native Emacs and using the sbt.bat in Windows 7. I guess I'll have to minimise the problem.

fommil commented 8 years ago

The suggestion is to disable buffering in SBT https://groups.google.com/forum/m/#!topic/gnu.emacs.help/KPYbNh1vgzk

This may require wrapping SBT in an unbuffer command that does this for us.

fommil commented 8 years ago

Somebody suggested disabling jline in the SBT gitter channel. I have high hopes of fixing this tomorrow without any changes needed!

fommil commented 8 years ago

that was it! adding -Djline.terminal=jline.UnsupportedTerminal to the sbt options fixed the problem.