zsh-users
 help / color / mirror / code / Atom feed
From: johnnonedoe@aol.com
To: "zsh-users@zsh.org" <zsh-users@zsh.org>
Subject: read -u 0 -k 1 does not work as advertised.
Date: Sat, 30 Jul 2022 22:28:10 +0000 (UTC)	[thread overview]
Message-ID: <1885158736.4353982.1659220090997@mail.yahoo.com> (raw)
In-Reply-To: <1885158736.4353982.1659220090997.ref@mail.yahoo.com>

[-- Attachment #1: Type: text/plain, Size: 604 bytes --]

As illustrated below:
◼︎◼︎▶︎ which g1 g2                       

g1 () {

 REPLY=timeout 

 read -t 5 -k 1

 echo REPLY=$REPLY

}

g2 () {

 REPLY=timeout 

 read -u 0 -t 5 -k 1

 echo REPLY=$REPLY

}

◼︎◼︎▶︎ g1         # no return                          

aaREPLY=a

◼︎◼︎▶︎ g2                                   

asdf           # return

REPLY=a

◼︎◼︎▶︎ sdf                                

zsh: command not found: sdf


johnnonedoe@aol.com

[-- Attachment #2: Type: text/html, Size: 7554 bytes --]

           reply	other threads:[~2022-07-30 22:29 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <1885158736.4353982.1659220090997.ref@mail.yahoo.com>]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1885158736.4353982.1659220090997@mail.yahoo.com \
    --to=johnnonedoe@aol.com \
    --cc=zsh-users@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).