From mboxrd@z Thu Jan 1 00:00:00 1970 MIME-Version: 1.0 In-Reply-To: <5EF90081E9B1D745047218E6@192.168.1.2> References: <1239082320.2778.20.camel@katy-laptop> <140e7ec30904070053p20e60905y19a031837edc1931@mail.gmail.com> <3AB58E51F3A5C561C4B065E3@192.168.1.2> <140e7ec30904070731v7365aea2o7753be79bbaab8ea@mail.gmail.com> <13426df10904070809v2c536289vfa8485aabef7f2f0@mail.gmail.com> <3aaafc130904071257h4c7004c2ub7111f09055a9d8c@mail.gmail.com> <3aaafc130904072004v77277c42ic7f7447eeb8d7e36@mail.gmail.com> <5EF90081E9B1D745047218E6@192.168.1.2> Date: Thu, 9 Apr 2009 13:32:54 -0400 Message-ID: <3aaafc130904091032j3d3a2d59hef9fe291863cf3aa@mail.gmail.com> From: "J.R. Mauro" To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [9fans] a bit OT, programming style question Topicbox-Message-UUID: d7460c26-ead4-11e9-9d60-3106f5b1d025 On Thu, Apr 9, 2009 at 9:44 AM, Eris Discordia w= rote: >> Try env | wc -l in bash. Now tell me why that value is so big. > >> [root@host ~]# env | wc -l >> =A0 =A0 =A0 =A037 >> [root@host ~]# > > Is that very high? I don't even know if it is or how it would mean anythi= ng > bad (or good for that matter) assuming it were high. Not to mention, it's= a > very bad metric. Because: > >> [root@host ~]# env | wc -c >> =A0 =A0 =A0 =A01404 >> [root@host ~]# > > Most of it in the 19 lines for one TERMCAP variable. Strictly a relic of = the > past kept with all good intentions: backward compatibility, and heeding t= he > diversity of hardware and configuration that still exists out there. 5 of > the other 18 lines are completely specific to my installation. That leave= s > us with 13 short lines. Grumble... s/env/set And then you see the guts of bash spill out. > > Quite a considerable portion of UNIX-like systems, FreeBSD in this case, = is > the way it is not because the developers are stupid, rather because they > have a "constituency" to tend to. They aren't carefree researchers with h= igh > ambitions. I leveled no claims against *BSD or Linux. I'm simply trying to point out that bash is utter garbage, as its own man page indicates. > > --On Tuesday, April 07, 2009 11:04 PM -0400 "J.R. Mauro" > wrote: > >> On Tue, Apr 7, 2009 at 9:48 PM, Eris Discordia >> wrote: >>>> >>>> The man page *does* say it's too big and slow. So does the bash >>>> manpage. And getting readline to do anything sane is about as fun as >>>> screwing around with a terminfo file. >>> >>> A bad implementation is not a bad design. And, in fact, the badness of >>> the implementation is even questionable in the light of bash's normal >>> behavior or the working .inputrc files I've been using for some time. >> >> Behavior is not indicative of good design. It just means that the >> bandaids heaped upon bash (and X11, and...) make it work acceptably. >> >> Try env | wc -l in bash. Now tell me why that value is so big. >> >>> >>> Anyway, thanks for the info. >>> >>> --On Tuesday, April 07, 2009 3:57 PM -0400 "J.R. Mauro" >>> wrote: >>> >>>> On Tue, Apr 7, 2009 at 2:21 PM, Eris Discordia >>>> wrote: >>>>> >>>>> I see. But seriously, readline does handle bindings and line editing >>>>> for bash. Except it's a function instead of a program and you think >>>>> it's a bad idea. >>>> >>>> The man page *does* say it's too big and slow. So does the bash >>>> manpage. And getting readline to do anything sane is about as fun as >>>> screwing around with a terminfo file. >>>> >>>>> >>>>> --On Tuesday, April 07, 2009 10:31 PM +0800 sqweek >>>>> wrote: >>>>> >>>>>> 2009/4/7 Eris Discordia : >>>>>>>>> >>>>>>>>> Keyboard >>>>>>>>> bindings for example; why couldn't they be handled by a program >>>>>>>>> that just does keyboard bindings + line editing, and writes >>>>>>>>> finalized lines to the shell. >>>>>>> >>>>>>> Like... readline(3)? >>>>>> >>>>>> =A0No. >>>>>> -sqweek >>>>>> >>>>> >>>>> >>>>> >>>>> --On Tuesday, April 07, 2009 8:09 AM -0700 ron minnich >>>>> wrote: >>>>> >>>>>> On Tue, Apr 7, 2009 at 12:28 AM, Eris Discordia >>>>>> wrote: >>>>>> >>>>>>> >>>>>>> Like... readline(3)? >>>>>> >>>>>> one hopes not. >>>>>> >>>>>> ron >>>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> >>> >>> >> > >