From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HTML_MESSAGE,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 3580 invoked from network); 31 Jul 2021 23:26:42 -0000 Received: from minnie.tuhs.org (45.79.103.53) by inbox.vuxu.org with ESMTPUTF8; 31 Jul 2021 23:26:42 -0000 Received: by minnie.tuhs.org (Postfix, from userid 112) id E64209CA4C; Sun, 1 Aug 2021 09:26:35 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id 4FA8E9C9B4; Sun, 1 Aug 2021 09:26:17 +1000 (AEST) Authentication-Results: minnie.tuhs.org; dkim=pass (2048-bit key; unprotected) header.d=bsdimp-com.20150623.gappssmtp.com header.i=@bsdimp-com.20150623.gappssmtp.com header.b="yPfyWyWp"; dkim-atps=neutral Received: by minnie.tuhs.org (Postfix, from userid 112) id 106679C9B4; Sun, 1 Aug 2021 09:26:14 +1000 (AEST) Received: from mail-qt1-f182.google.com (mail-qt1-f182.google.com [209.85.160.182]) by minnie.tuhs.org (Postfix) with ESMTPS id B01CF9C9B2 for ; Sun, 1 Aug 2021 09:26:12 +1000 (AEST) Received: by mail-qt1-f182.google.com with SMTP id x9so9182983qtw.13 for ; Sat, 31 Jul 2021 16:26:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Cyq52FKrRBRo1/kCoVOZZ7laiD8PsWnU5sFcuB2l7pI=; b=yPfyWyWpul60uRRAKyMoXYj3DCZfdHvto3VsEM8UW7ZR38SEReY/nfzvJzzPwlEQPZ KyfrS+jgqgLYYPM2PT5dP8IWQLQ6aa/+Ptm4H86SNI84fmMuwQ2N9iB38Erc3GYwUUmr 4gRXY5ODu+dkn6HwtDazgaLId1jQrz8z2yoXZa+SiHvq+93ZoQ6ehA7QdHujYeR8xBg5 Prwd9Popdcjllnfh5cWccVaT9YacVXTPHbrCB4WgheEqWyiuMC2S7FpfT7c1OOmQnp3I WPPq8bFa0OYfSB3gnC1Vk0PIb6kDPgxGqnMddEW7H/mj2cyd03Vh/cnjnvhiRqWbpLKH hpIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Cyq52FKrRBRo1/kCoVOZZ7laiD8PsWnU5sFcuB2l7pI=; b=KXEycpeU/1zUyYBTzwfCOha6u7XNJxmTtVQbP9evcW8drq2M16ttwVfXHeMXIBKJpQ ZgC1VTtBwR9obxE+P5i0WWONnCuI41VyNdKNDgotXN6BfF3CjqCUdoqPiDFgL0W+iKgT mlEfwv3J+9hXPqmWjTptpiTI0oE6YTC6Fht93jUaYArBVJXJ+434UoXOFxOdwl1IF53G /A7fDnuLr34e+zkoFAkzwF2BkKn+51nSnFZYK3Wskd61CkO9JWgY5d1KThyKWFremq1U SsDDeEjIPUuiTFGBwj2APYLaY8lEQ2wMVLTQOL0aUPGo3ldqgOIcuy1Xs4dpHt4BtGj1 i5Qw== X-Gm-Message-State: AOAM533bLUKr25zH3xQ1U5ZQvzyTp0PeYxMhPmuZMAwQv/cVuzoY/soY bncieYj1AVMAilax6chgUYbrLvhnwdDQeeF9pc0XNw== X-Google-Smtp-Source: ABdhPJzWrvbjMUChBNOF909p9P1Bjvtuq+DK5TjNsDsjxWDdlkFasqvW+xvnn8Ip3wU3d0okv10/3HCXWS13hEf7A7o= X-Received: by 2002:ac8:6645:: with SMTP id j5mr8191173qtp.244.1627773971705; Sat, 31 Jul 2021 16:26:11 -0700 (PDT) MIME-Version: 1.0 References: <20210731142533.69caf929@moon> <202107311920.16VJK2jT2362871@fourwinds.com> <202107312132.16VLW6VD2410038@fourwinds.com> <202107312220.16VMKDd92449332@fourwinds.com> In-Reply-To: <202107312220.16VMKDd92449332@fourwinds.com> From: Warner Losh Date: Sat, 31 Jul 2021 17:26:00 -0600 Message-ID: To: Jon Steinhart Content-Type: multipart/alternative; boundary="0000000000005bc56305c873a94b" Subject: Re: [TUHS] Systematic approach to command-line interfaces [ meta issues ] X-BeenThere: tuhs@minnie.tuhs.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: The Unix Heritage Society mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: TUHS main list Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" --0000000000005bc56305c873a94b Content-Type: text/plain; charset="UTF-8" On Sat, Jul 31, 2021 at 4:37 PM Jon Steinhart wrote: > Warner Losh writes: > > > > The flip side to this is that libraries can be debugged once, while > inline > > code like the above needs to be deugged over and over.... > > Well, no. Inline code doesn't need to be debugged over and over. It > doesn't > have to be written from scratch every time. While in theory your point > about > libraries is correct, it hasn't seem to have worked out in practice. > Better > in C than in node.js, but there have been plenty of spectacular bugs found > in > old C libraries recently. > The large number of times I've had to replace inline code like you've quoted with getopt to fix the irregularities in command line parsing suggests that we differ on this viewpoint. Warner --0000000000005bc56305c873a94b Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Sat, Jul 31, 2021 at 4:37 PM Jon S= teinhart <jon@fourwinds.com>= wrote:
Warner L= osh writes:
>
> The flip side to this is that libraries can be debugged once, while in= line
> code like the above needs to be deugged over and over....

Well, no.=C2=A0 Inline code doesn't need to be debugged over and over.= =C2=A0 It doesn't
have to be written from scratch every time.=C2=A0 While in theory your poin= t about
libraries is correct, it hasn't seem to have worked out in practice.=C2= =A0 Better
in C than in node.js, but there have been plenty of spectacular bugs found = in
old C libraries recently.

The large num= ber of times I've had to replace inline code like you've quoted wit= h
getopt to fix the irregularities in command line parsing sugges= ts that we differ on
this viewpoint.

War= ner=C2=A0
--0000000000005bc56305c873a94b--