* Thorsten Glaser <[email protected]> [2013-11-26 18:04]:
> Stefan Heine dixit:
>
>> on pdksh, I get an output showing one multi-line entry:
>>
>> [...]
>> 16      echo "
>>        foo
>>        bar"
>
> That is not pdksh.
>
> tg@blau:/tmp/p/pdksh-5.2.14 $ PS1='x ' pdksh
> x echo "a
>> b"
> a
> b
> x set -o emacs
> x history
> 1       echo "a
> 2       b"
> 3       set -o emacs
>
> Another thing, multi-line editing is not doable portably
> without involving some beast like libtermcap or terminfo
> because you cannot portably go “one line up”. Although a
> multi-line command line input editing mode is on even my
> own wishlist for years I believe we will not do that.

Not being able to edit a multi-line command in the builtin editor
is not a big deal (and the same in ksh93 and ksh88), however
storing each line as a separate history entry is IMHO broken
because such history entries become essentially useless as they
cannot be re-input.
Could you modify the history code to store multiple lines as a
single item? I just checked and that is the behavior of the
original ksh88 and also ksh93, it make sense since it still
allows one to re-input such commands via fc.
-- 
Guido Berhoerster

Reply via email to