zsh-workers
 help / color / mirror / code / Atom feed
* When is STTY ignored?
@ 2017-05-29 20:36 Stephane Chazelas
  2017-05-30  0:02 ` Bart Schaefer
  0 siblings, 1 reply; 4+ messages in thread
From: Stephane Chazelas @ 2017-05-29 20:36 UTC (permalink / raw)
  To: Zsh hackers list

Hello,

It's not very clear to me when one may use STTY.

STTY=-echo line
zsh -c 'STTY=-echo line'
STTY=-echo command line
f() line; STTY=-echo f
f() STTY=-echo line; f

work (at reading a line with tty echo disabled)

But:

STTY=-echo read line
STTY=-echo eval line
zsh -c 'f() line; STTY=-echo f'
zsh -c 'f() STTY=-echo line; f'

don't (stty not run).

See also:

$ f() STTY=-onlcr line; STTY=-echo f; stty
asd
   asd
      speed 38400 baud; line = 0;
                                 -brkint -imaxbel iutf8
                                                       -onlcr

-echo not applied, -onlcr not restored.

-- 
Stephane


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

end of thread, other threads:[~2017-05-31  6:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-29 20:36 When is STTY ignored? Stephane Chazelas
2017-05-30  0:02 ` Bart Schaefer
2017-05-30  6:53   ` Stephane Chazelas
2017-05-31  6:27     ` Bart Schaefer

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

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 NNTP newsgroup(s).