From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Sam Halliday Newsgroups: gmane.emacs.help Subject: Re: Comint and windows Date: Sat, 7 Nov 2015 09:21:32 -0800 (PST) Message-ID: <1a191a70-5ac8-4727-919b-774c91a642e4@googlegroups.com> References: <4b118c46-2d1a-4547-b889-02153639a401@googlegroups.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: ger.gmane.org 1446917124 29739 80.91.229.3 (7 Nov 2015 17:25:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 7 Nov 2015 17:25:24 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Nov 07 18:25:20 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Zv7Et-00079K-Ai for geh-help-gnu-emacs@m.gmane.org; Sat, 07 Nov 2015 18:25:19 +0100 Original-Received: from localhost ([::1]:44729 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zv7Es-0004xt-Lm for geh-help-gnu-emacs@m.gmane.org; Sat, 07 Nov 2015 12:25:18 -0500 X-Received: by 10.129.73.198 with SMTP id w189mr18112652ywa.5.1446916893705; Sat, 07 Nov 2015 09:21:33 -0800 (PST) X-Received: by 10.50.8.68 with SMTP id p4mr377235iga.8.1446916893675; Sat, 07 Nov 2015 09:21:33 -0800 (PST) Original-Path: usenet.stanford.edu!f78no227404qge.1!news-out.google.com!fs1ni1922igb.0!nntp.google.com!i2no558728igv.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=86.21.102.205; posting-account=kRukCAoAAAANs-vsVh9dFwo5kp5pwnPz Original-NNTP-Posting-Host: 86.21.102.205 User-Agent: G2/1.0 Injection-Date: Sat, 07 Nov 2015 17:21:33 +0000 Original-Xref: usenet.stanford.edu gnu.emacs.help:215696 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:107982 Archived-At: Thanks Eli, that was exactly it! It was possible to tell the subprogram (a Java app that uses jline) to not buffer and everything started to work. On Thursday, 5 November 2015 16:22:48 UTC, Eli Zaretskii wrote: > > Date: Thu, 5 Nov 2015 00:12:51 -0800 (PST) > > From: Sam Halliday > > > > I've been forced to use Windows at work and I'm finding some of my modes don't work. > > > > One mode that is not working for me is sbt-mode: > > > > https://github.com/hvesalai/sbt-mode/issues/33 > > > > It is a pretty standard implementation of a major mode that talks to an external process via comint. But it looks like commands typed in emacs are not being sent to the process. > > > > Are there any known gotchas with writing these sorts of modes to run on windows? > > Yes. It's likely a buffering issue. Windows doesn't have pty's, so > communications with subprocesses is via pipes, which fail the isatty > test, and so the subprocess most probably buffers its standard > streams because it doesn't sense that they are connected to a terminal > device. > > Try invoking the subprocess in a way that disables buffering of > stdin/stdout on the subprocess's side. It could be some command-line > switch or maybe some command you need to invoke immediately after > invoking the subprocess. (If there's no such option, ask the > developers to provide one, or hack the code yourself.)