* How to read into variable with readline support? @ 2018-01-16 18:42 Andy Spiegl 2018-01-16 19:44 ` Eric Cook 0 siblings, 1 reply; 3+ messages in thread From: Andy Spiegl @ 2018-01-16 18:42 UTC (permalink / raw) To: Zsh Users I would like to read input from the keyboard (like "read $VAR") but with editing and history support. I'm sure zsh offers this but I am too stupid to find out how. Thanks! Andy -- Always borrow money from a pessimist, he doesn't expect to be paid back. ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: How to read into variable with readline support? 2018-01-16 18:42 How to read into variable with readline support? Andy Spiegl @ 2018-01-16 19:44 ` Eric Cook 2018-01-18 16:29 ` Andy Spiegl 0 siblings, 1 reply; 3+ messages in thread From: Eric Cook @ 2018-01-16 19:44 UTC (permalink / raw) To: zsh-users On 01/16/2018 01:42 PM, Andy Spiegl wrote: > I would like to read input from the keyboard (like "read $VAR") but > with editing and history support. I'm sure zsh offers this but I am > too stupid to find out how. > > Thanks! > Andy > People normally use vared, which uses zle for line editing. vared -c var you can even change the completion used with it: () { local compcontext='hosts:hostname:_hosts' vared -cp 'choose a host ' ans } ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: How to read into variable with readline support? 2018-01-16 19:44 ` Eric Cook @ 2018-01-18 16:29 ` Andy Spiegl 0 siblings, 0 replies; 3+ messages in thread From: Andy Spiegl @ 2018-01-18 16:29 UTC (permalink / raw) To: zsh-users > People normally use vared, which uses zle for line editing. Thanks, Eric, exactly what I was looking for! Andy -- It is a profitable thing, if one is wise, to seem foolish. (Aeschylus) ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-01-18 16:29 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2018-01-16 18:42 How to read into variable with readline support? Andy Spiegl 2018-01-16 19:44 ` Eric Cook 2018-01-18 16:29 ` Andy Spiegl
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).