tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Input line editing



>> * Per-application differences (perhaps most notably input line
>> history).  Possible solution: editor process watches the tty process
>> group.
> I think the issue is that I don't necessarily want the history to
> follow the tty.  I tend to prefer it to follow the application -- and
> that creates its own weirdness.  Sometimes I want my shells to share
> a history, sometimes I want it to be one each.

Share a history at run time, as in you type a command in one and it is
available next keystroke in another?  Or share a history as in the
~/.history style?  I assume the former.  (I've occasionally wanted it
too, but it's looked too intimidating to implement.  Something like
this actually seems to me like the right way to do it.)

This is actually made easier by the design I have in mind, as the input
editor processes for the various (pseudo-)ttys in question can
collaborate - or, hm, perhaps all be just one process? - to give you
what you want without having to rig all applications you want that in
to play nice with one another, and without making those who don't want
it pay the (admittedly probably fairly small) penalty of having that
intricacy in the application when they run it.  There's the question of
identifying which processes are running applications you want to have
sharing stuff, but that's no worse than identifying applications to
begin with.

> I do like the basic idea of providing a general interface, but I'm
> not sure how to reconcile it with the large amount of code tied to
> specific libraries.

API/ABI-compatible implentations of those libraries' interfaces that,
instead of doing input line editing, are just glue code to the common
line editor.  That's what I had in mind for that.  Do you see any
reason it wouldn't be workable?

The biggest problem would, I expect, be line editors in applications
that are fairly closely coupled with the application.  I expect the
first couple of iterations of the application<->editor interface to be
very experimental - quickly found inadequate and replaced.

I'm starting to feel fired up.  I should probably go off and have a
stab at a first cut at this, find out just how much real trouble I'm
handwaving away and how much my feeling that there isn't any real
problem being ignored is accurate.

/~\ The ASCII                             Mouse
\ / Ribbon Campaign
 X  Against HTML                mouse%rodents-montreal.org@localhost
/ \ Email!           7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B


Home | Main Index | Thread Index | Old Index