public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Cannot change console mode during usage of expect
@ 2015-04-15  1:20 Keith Proctor
  2015-04-15  7:33 ` Corinna Vinschen
  2015-04-16  0:29 ` Keith Proctor
  0 siblings, 2 replies; 13+ messages in thread
From: Keith Proctor @ 2015-04-15  1:20 UTC (permalink / raw)
  To: cygwin

Hello, my name is Keith Proctor.  I test FileMaker Server and I have written 
a test suite on Macintosh. The tests work beautifully on  Macintosh. I’m trying
to Use Cygwin on Windows to reduce the amount of rewriting that I must do 
on the Windows side.    The test includes a dynamically created interactive call
that uses expect to spawn fmsadmin and then interact with fmsadmin by 
providing a user name or a password.  An example is below:

expect -c "spawn fmsadmin open -y -u userName
expect -r .+:
send myPassword\r
interact"

The issue is that the following phrases appear and won’t allow my interactive 
expect command to continue.

GetConsoleMode	// prints once
SetConsoleMode	// prints once
ReadConsoleInput	// spews while collecting input from the command line.

Perform the actions of the script above by hand in the Cygwin CLI does NOT 
cause an issue.  The issue only happens when using expect.  I have tried 3
shells so far (mintty, bash, rxvt).  Are there more?  Mintty provides access to
the terminal types.  So far I have tried xterm-256, vt100, vt120.

An example of the code looks like:

   fdwMode = ENABLE_WINDOW_INPUT | ENABLE_MOUSE_INPUT
          | ENABLE_PROCESSED_INPUT; 
   if (! SetConsoleMode(hStdin, fdwMode) )
		// print error to console

Since FileMaker Server runs on Macintosh or Windows it is doubtful that
I can get a change made in the fmsadmin application. I’m new to CygWin
so I’m hoping that I’ve missed a setting somewhere or maybe I need to
install another module.  

Help me Obi-Wan your my only hope.  ;)

Keith

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2015-04-16 21:37 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-04-15  1:20 Cannot change console mode during usage of expect Keith Proctor
2015-04-15  7:33 ` Corinna Vinschen
2015-04-15 17:57   ` Keith Proctor
2015-04-15 21:53     ` Mark Geisert
2015-04-15 22:21       ` Keith Proctor
2015-04-15 22:36         ` Mark Geisert
2015-04-15 23:08           ` Keith Proctor
2015-04-16  7:36     ` Corinna Vinschen
2015-04-16  0:29 ` Keith Proctor
2015-04-16  4:37   ` Marco Atzeri
2015-04-16  6:20     ` Keith Proctor
2015-04-16 19:39       ` Marco Atzeri
2015-04-16 21:37         ` Keith Proctor

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).