The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
* [TUHS] nl section delimiters
@ 2024-05-11  2:19 Douglas McIlroy
  2024-05-11 20:48 ` [TUHS] " Steffen Nurpmeso
  0 siblings, 1 reply; 8+ messages in thread
From: Douglas McIlroy @ 2024-05-11  2:19 UTC (permalink / raw)
  To: TUHS main list

[-- Attachment #1: Type: text/plain, Size: 136 bytes --]

> But it misses the coolness of the empty true(1).

Too cool. With an empty true(1), execl("true", "true", 0) is out in the
cold.

Doug

[-- Attachment #2: Type: text/html, Size: 264 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [TUHS] Re: nl section delimiters
  2024-05-11  2:19 [TUHS] nl section delimiters Douglas McIlroy
@ 2024-05-11 20:48 ` Steffen Nurpmeso
  2024-05-13 13:12   ` Chet Ramey
  0 siblings, 1 reply; 8+ messages in thread
From: Steffen Nurpmeso @ 2024-05-11 20:48 UTC (permalink / raw)
  To: Douglas McIlroy; +Cc: TUHS main list

Douglas McIlroy wrote in
 <CAKH6PiWG-cFwQYPKDhKg_LdDKChC8odbxnnTOjC9+KZea7OgQA@mail.gmail.com>:
 |> But it misses the coolness of the empty true(1).
 |
 |Too cool. With an empty true(1), execl("true", "true", 0) is out in the
 |cold.

There i stand singing "ein Männlein steht im Walde" (a "little
man" stands in the forest).

..ok, but then i do note here and now the certain lists where the
question on whether an additional entry in the search path does
make any sense at all for certain constructs comes up regulary,
(even) i have lived this multiple times already, it is about

  The [.] command search [.] allows for a standard utility to be
  implemented as a regular built-in as long as it is found in the
  appropriate place in a PATH search.
  [.]command -v true might yield /bin/true or some similar pathname.

  Other [non-standard] utilities [.] might exist only as built-ins
  and have no pathname associated with them. These produce output
  identified as (regular) built-ins. Applications encountering
  these are not able to count on execing them, using them with
  nohup, overriding them with a different PATH, and so on.

The next POSIX standard will have around 4058 pages (3950 without
index) and 137171 lines (not counting index).

And i was surely laughing when this list it surely was came along
this somewhen in the past, and isn't that just "a muscle car":

  #?0|kent:unix-hist$ git show Research-V7:bin/true | wc -c
  0

Many greetings and best wishes!!

--steffen
|
|Der Kragenbaer,                The moon bear,
|der holt sich munter           he cheerfully and one by one
|einen nach dem anderen runter  wa.ks himself off
|(By Robert Gernhardt)

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [TUHS] Re: nl section delimiters
  2024-05-11 20:48 ` [TUHS] " Steffen Nurpmeso
@ 2024-05-13 13:12   ` Chet Ramey
  0 siblings, 0 replies; 8+ messages in thread
From: Chet Ramey @ 2024-05-13 13:12 UTC (permalink / raw)
  To: Douglas McIlroy, TUHS main list


[-- Attachment #1.1: Type: text/plain, Size: 673 bytes --]

On 5/11/24 4:48 PM, Steffen Nurpmeso wrote:

>    The [.] command search [.] allows for a standard utility to be
>    implemented as a regular built-in as long as it is found in the
>    appropriate place in a PATH search.
>    [.]command -v true might yield /bin/true or some similar pathname.

To be fair, no one really implements this. ksh93 is the shell that comes
closest.

The next edition of the standard acknowledges the status quo with the
`intrinsics' concept.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 203 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [TUHS] Re: nl section delimiters
  2024-05-10 16:50   ` John P. Linderman
  2024-05-10 23:05     ` Steffen Nurpmeso
@ 2024-05-11  9:07     ` Ralph Corderoy
  1 sibling, 0 replies; 8+ messages in thread
From: Ralph Corderoy @ 2024-05-11  9:07 UTC (permalink / raw)
  To: tuhs

Hi jpl,

> Instead of taking the time to go through the alphabet soup of options
> to nl and pr and ls, learning a tool like awk or perl or python

pr(1) was in V5, where one of its stderr messages was ‘Very funny.’.
awk arrived in V7.

-- 
Cheers, Ralph.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [TUHS] Re: nl section delimiters
  2024-05-10 16:50   ` John P. Linderman
@ 2024-05-10 23:05     ` Steffen Nurpmeso
  2024-05-11  9:07     ` Ralph Corderoy
  1 sibling, 0 replies; 8+ messages in thread
From: Steffen Nurpmeso @ 2024-05-10 23:05 UTC (permalink / raw)
  To: John P. Linderman; +Cc: tuhs

John P. Linderman wrote in
 <CAC0cEp-E8f8nXaCMM34opqcgPQFpOQnE6Z9m3g1o4N_ET5-nsA@mail.gmail.com>:
 |I'll accept Rob's theory. Instead of taking the time to go through the
 |alphabet soup of options to nl and pr and ls, learning a tool like awk or
 |perl or python makes implementing most of what these commands do (or what
 |you wish they could do) a one-finger exercise. -- jpl

But it misses the coolness of the empty true(1), and the last
possibly requires more CPU cycles for startup than you had on
a work day (said into the blue, completely unmathematically).

--steffen
|
|Der Kragenbaer,                The moon bear,
|der holt sich munter           he cheerfully and one by one
|einen nach dem anderen runter  wa.ks himself off
|(By Robert Gernhardt)

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [TUHS] Re: nl section delimiters
  2024-05-10 10:08 ` [TUHS] " Rob Pike
  2024-05-10 16:05   ` segaloco via TUHS
@ 2024-05-10 16:50   ` John P. Linderman
  2024-05-10 23:05     ` Steffen Nurpmeso
  2024-05-11  9:07     ` Ralph Corderoy
  1 sibling, 2 replies; 8+ messages in thread
From: John P. Linderman @ 2024-05-10 16:50 UTC (permalink / raw)
  To: Rob Pike; +Cc: tuhs

[-- Attachment #1: Type: text/plain, Size: 1513 bytes --]

I'll accept Rob's theory. Instead of taking the time to go through the
alphabet soup of options to nl and pr and ls, learning a tool like awk or
perl or python makes implementing most of what these commands do (or what
you wish they could do) a one-finger exercise. -- jpl

On Fri, May 10, 2024 at 6:09 AM Rob Pike <robpike@gmail.com> wrote:

> Didn't recognize the command, looked it up. Sigh.
>
>   pr -tn <file>
>
> seems sufficient for me, but then that raises the question of your
> question.
>
> I've been developing a theory about how the existence of something leads
> to things being added to it that you didn't need at all and only thought of
> when the original thing was created. Bloat by example, if you will. I
> suspect it will not be a popular theory, however accurately it may describe
> the technological world.
>
> -rob
>
>
> On Fri, May 10, 2024 at 4:16 PM David Arnold <davida@pobox.com> wrote:
>
>> nl(1) uses the notable character sequences “\:\:\:”, “\:\:”, and “\:” to
>> delimit header, body, and trailer sections within its input.
>>
>> I wondered if anyone was able to shed light on the reason those were
>> adopted as the defaults?
>>
>> I would have expected perhaps something compatible with *roff (like, .\”
>> something).
>>
>> FreeBSD claims nl first appeared in System III (although it previously
>> claimed SVR2), but I haven’t dug into the implementation any further.
>>
>> Thanks in advance,
>>
>>
>>
>> d
>>
>

[-- Attachment #2: Type: text/html, Size: 2827 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [TUHS] Re: nl section delimiters
  2024-05-10 10:08 ` [TUHS] " Rob Pike
@ 2024-05-10 16:05   ` segaloco via TUHS
  2024-05-10 16:50   ` John P. Linderman
  1 sibling, 0 replies; 8+ messages in thread
From: segaloco via TUHS @ 2024-05-10 16:05 UTC (permalink / raw)
  To: The Eunuchs Hysterical Society

On Friday, May 10th, 2024 at 3:08 AM, Rob Pike <robpike@gmail.com> wrote:

> Didn't recognize the command, looked it up. Sigh.
> 
> pr -tn <file>
> 
> seems sufficient for me, but then that raises the question of your question.
> 
> I've been developing a theory about how the existence of something leads to things being added to it that you didn't need at all and only thought of when the original thing was created. Bloat by example, if you will. I suspect it will not be a popular theory, however accurately it may describe the technological world.
> 
> -rob
> 
> 
> On Fri, May 10, 2024 at 4:16 PM David Arnold <davida@pobox.com> wrote:
> 
> > nl(1) uses the notable character sequences “\:\:\:”, “\:\:”, and “\:” to delimit header, body, and trailer sections within its input.
> > 
> > I wondered if anyone was able to shed light on the reason those were adopted as the defaults?
> > 
> > I would have expected perhaps something compatible with *roff (like, .\” something).
> > 
> > FreeBSD claims nl first appeared in System III (although it previously claimed SVR2), but I haven’t dug into the implementation any further.
> > 
> > Thanks in advance,
> > 
> > 
> > 
> > d

https://www.tuhs.org/pipermail/tuhs/2022-July/026197.html

Here's an earlier thread on nl that doesn't answer your specific question on the sequences but may provide some background on nl(1).

- Matt G.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [TUHS] Re: nl section delimiters
  2024-05-10  6:15 [TUHS] " David Arnold
@ 2024-05-10 10:08 ` Rob Pike
  2024-05-10 16:05   ` segaloco via TUHS
  2024-05-10 16:50   ` John P. Linderman
  0 siblings, 2 replies; 8+ messages in thread
From: Rob Pike @ 2024-05-10 10:08 UTC (permalink / raw)
  To: David Arnold; +Cc: tuhs

[-- Attachment #1: Type: text/plain, Size: 1110 bytes --]

Didn't recognize the command, looked it up. Sigh.

  pr -tn <file>

seems sufficient for me, but then that raises the question of your question.

I've been developing a theory about how the existence of something leads to
things being added to it that you didn't need at all and only thought of
when the original thing was created. Bloat by example, if you will. I
suspect it will not be a popular theory, however accurately it may describe
the technological world.

-rob


On Fri, May 10, 2024 at 4:16 PM David Arnold <davida@pobox.com> wrote:

> nl(1) uses the notable character sequences “\:\:\:”, “\:\:”, and “\:” to
> delimit header, body, and trailer sections within its input.
>
> I wondered if anyone was able to shed light on the reason those were
> adopted as the defaults?
>
> I would have expected perhaps something compatible with *roff (like, .\”
> something).
>
> FreeBSD claims nl first appeared in System III (although it previously
> claimed SVR2), but I haven’t dug into the implementation any further.
>
> Thanks in advance,
>
>
>
> d
>

[-- Attachment #2: Type: text/html, Size: 2120 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2024-05-13 13:12 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-11  2:19 [TUHS] nl section delimiters Douglas McIlroy
2024-05-11 20:48 ` [TUHS] " Steffen Nurpmeso
2024-05-13 13:12   ` Chet Ramey
  -- strict thread matches above, loose matches on Subject: below --
2024-05-10  6:15 [TUHS] " David Arnold
2024-05-10 10:08 ` [TUHS] " Rob Pike
2024-05-10 16:05   ` segaloco via TUHS
2024-05-10 16:50   ` John P. Linderman
2024-05-10 23:05     ` Steffen Nurpmeso
2024-05-11  9:07     ` Ralph Corderoy

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).