The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
* [TUHS] Where did the "~" come from
@ 2020-11-18 22:25 Clem Cole
  2020-11-18 22:41 ` Dave Horsfall
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Clem Cole @ 2020-11-18 22:25 UTC (permalink / raw)
  To: The Eunuchs Hysterical Society

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

A couple of my friends from UC Berkeley were musing on another email
thread.    The question from one of them came up: *"I'm teaching the
undergrad OS course this semester  ... Mention where ~ comes."*

This comment begets a discussion among the 4 of us at where it showed up in
the UNIX heritage and it if was taken from somewhere else.

Using the tilde character as a short cut for $HOME was purely a userspace
convention and not part of the nami() kernel routine when it came into
being.  We know that it was supported by Mike Lesk in UUCP and by Bill Joy
in cshell.  The former was first widely released as part of Seventh Edition
but was working on V6 before that inside of BTL.  Joy's cshell came out as
part of 2BSD (which was V7 based), but he had released "ashell" before that
and included it in the original BSD (*a.k.a.* 1BSD) which was for V6 [what
I don't remember is if it supported the convention and I can not easily un-
ar(1) the cont.a files in the 1BSD tar image in Warren's archives.

In our exchange, someone observed suggested that Joy might have picked it
up because the HOME key was part of the tilde key on the ADM3A, which were
popular at UCB [*i.e.* the reason hjkl are the movement keys on vi is the
were embossed on the top of those keys on the ADM3A].  It also was noted
that the ASR-33 lacks a ~ key on its keyboard.  But Lesk definitely needed
something to represent a remote user's home directory because each system
was different, so he was forced to use something.

It was also noted that there was plenty of cross-pollination going on as
students and researchers moved from site to site, so it could have been BTL
to UCB, vice-versa, or some other path altogether.

So two questions for this august body are:

   1. Where did the ~ as $HOME convention come to UNIX?
   2. Did UNIX create the idiom, or was there an earlier system such as
   CTSS, TENEX, ITS, MTS, TSS, or the like supported it?

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

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

* Re: [TUHS] Where did the "~" come from
  2020-11-18 22:25 [TUHS] Where did the "~" come from Clem Cole
@ 2020-11-18 22:41 ` Dave Horsfall
  2020-11-19  0:44   ` George Michaelson
  2020-11-19 15:50 ` Warner Losh
  2020-11-19 17:22 ` Mary Ann Horton
  2 siblings, 1 reply; 9+ messages in thread
From: Dave Horsfall @ 2020-11-18 22:41 UTC (permalink / raw)
  To: The Eunuchs Hysterical Society

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

On Wed, 18 Nov 2020, Clem Cole wrote:

> In our exchange, someone observed suggested that Joy might have picked 
> it up because the HOME key was part of the tilde key on the ADM3A, which 
> were popular at UCB [i.e. the reason hjkl are the movement keys on vi is 
> the were embossed on the top of those keys on the ADM3A].  It also was 
> noted that the ASR-33 lacks a ~ key on its keyboard.  But Lesk 
> definitely needed something to represent a remote user's home directory 
> because each system was different, so he was forced to use something.

The ADM-3A was one of the best terminals ever made.

> It was also noted that there was plenty of cross-pollination going on as
> students and researchers moved from site to site, so it could have been BTL
> to UCB, vice-versa, or some other path altogether.
> 
> So two questions for this august body are:
>  1. Where did the ~ as $HOME convention come to UNIX?

Gawd...  I think I saw it in PWB, but I'm likely wrong.

>  2. Did UNIX create the idiom, or was there an earlier system such as CTSS,
>     TENEX, ITS, MTS, TSS, or the like supported it?

No idea. but given that Unix inherited a lot of stuff....

-- Dave

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

* Re: [TUHS] Where did the "~" come from
  2020-11-18 22:41 ` Dave Horsfall
@ 2020-11-19  0:44   ` George Michaelson
  2020-11-19 13:45     ` Ron Natalie
  2020-11-19 16:16     ` Chet Ramey
  0 siblings, 2 replies; 9+ messages in thread
From: George Michaelson @ 2020-11-19  0:44 UTC (permalink / raw)
  To: Dave Horsfall; +Cc: The Eunuchs Hysterical Society

A related but different "thing" is when the cd activity became a
pushdown stack of 2 (is it more? I never bothered checking)

somebody realised going "there and back again" was innately useful.

(I will never forget working on systems which had cd-moral-equivalent
<down> and no cd-moral-equivalent <up> but having cd-moral-equivalent
$HOME making all directory traversals downward, or back to your
personal root)

sorry for thread hijack.

-G

On Thu, Nov 19, 2020 at 8:42 AM Dave Horsfall <dave@horsfall.org> wrote:
>
> On Wed, 18 Nov 2020, Clem Cole wrote:
>
> > In our exchange, someone observed suggested that Joy might have picked
> > it up because the HOME key was part of the tilde key on the ADM3A, which
> > were popular at UCB [i.e. the reason hjkl are the movement keys on vi is
> > the were embossed on the top of those keys on the ADM3A].  It also was
> > noted that the ASR-33 lacks a ~ key on its keyboard.  But Lesk
> > definitely needed something to represent a remote user's home directory
> > because each system was different, so he was forced to use something.
>
> The ADM-3A was one of the best terminals ever made.
>
> > It was also noted that there was plenty of cross-pollination going on as
> > students and researchers moved from site to site, so it could have been BTL
> > to UCB, vice-versa, or some other path altogether.
> >
> > So two questions for this august body are:
> >  1. Where did the ~ as $HOME convention come to UNIX?
>
> Gawd...  I think I saw it in PWB, but I'm likely wrong.
>
> >  2. Did UNIX create the idiom, or was there an earlier system such as CTSS,
> >     TENEX, ITS, MTS, TSS, or the like supported it?
>
> No idea. but given that Unix inherited a lot of stuff....
>
> -- Dave

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

* Re: [TUHS] Where did the "~" come from
  2020-11-19  0:44   ` George Michaelson
@ 2020-11-19 13:45     ` Ron Natalie
  2020-11-19 16:16     ` Chet Ramey
  1 sibling, 0 replies; 9+ messages in thread
From: Ron Natalie @ 2020-11-19 13:45 UTC (permalink / raw)
  To: The Eunuchs Hysterical Society

 Not only were they embossed on the keys but I believe those control keys moved the cursor in those directions.   The Adm 1 and 3 were some of my first terminals.  

Sent from my iPhone

> On Nov 18, 2020, at 19:46, George Michaelson <ggm@algebras.org> wrote:
> 
> A related but different "thing" is when the cd activity became a
> pushdown stack of 2 (is it more? I never bothered checking)
> 
> somebody realised going "there and back again" was innately useful.
> 
> (I will never forget working on systems which had cd-moral-equivalent
> <down> and no cd-moral-equivalent <up> but having cd-moral-equivalent
> $HOME making all directory traversals downward, or back to your
> personal root)
> 
> sorry for thread hijack.
> 
> -G
> 
>> On Thu, Nov 19, 2020 at 8:42 AM Dave Horsfall <dave@horsfall.org> wrote:
>> 
>>> On Wed, 18 Nov 2020, Clem Cole wrote:
>>> 
>>> In our exchange, someone observed suggested that Joy might have picked
>>> it up because the HOME key was part of the tilde key on the ADM3A, which
>>> were popular at UCB [i.e. the reason hjkl are the movement keys on vi is
>>> the were embossed on the top of those keys on the ADM3A].  It also was
>>> noted that the ASR-33 lacks a ~ key on its keyboard.  But Lesk
>>> definitely needed something to represent a remote user's home directory
>>> because each system was different, so he was forced to use something.
>> 
>> The ADM-3A was one of the best terminals ever made.
>> 
>>> It was also noted that there was plenty of cross-pollination going on as
>>> students and researchers moved from site to site, so it could have been BTL
>>> to UCB, vice-versa, or some other path altogether.
>>> 
>>> So two questions for this august body are:
>>> 1. Where did the ~ as $HOME convention come to UNIX?
>> 
>> Gawd...  I think I saw it in PWB, but I'm likely wrong.
>> 
>>> 2. Did UNIX create the idiom, or was there an earlier system such as CTSS,
>>>    TENEX, ITS, MTS, TSS, or the like supported it?
>> 
>> No idea. but given that Unix inherited a lot of stuff....
>> 
>> -- Dave

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

* Re: [TUHS] Where did the "~" come from
  2020-11-18 22:25 [TUHS] Where did the "~" come from Clem Cole
  2020-11-18 22:41 ` Dave Horsfall
@ 2020-11-19 15:50 ` Warner Losh
  2020-11-19 17:22 ` Mary Ann Horton
  2 siblings, 0 replies; 9+ messages in thread
From: Warner Losh @ 2020-11-19 15:50 UTC (permalink / raw)
  To: Clem Cole; +Cc: The Eunuchs Hysterical Society

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

On Wed, Nov 18, 2020 at 3:27 PM Clem Cole <clemc@ccc.com> wrote:

> Joy's cshell came out as part of 2BSD (which was V7 based), but he had
> released "ashell" before that and included it in the original BSD (
> *a.k.a.* 1BSD) which was for V6 [what I don't remember is if it supported
> the convention and I can not easily un-ar(1) the cont.a files in the 1BSD
> tar image in Warren's archives.
>

Looking at the ashell sources on the 1BSD tuhs utree viewer suggests that ~
wasn't there yet, but that it was planned:

sh.c:
...

	Features remaining to be fixed up and/or implemented
	======== ========= == == ===== == === == ===========

...

 * Changes to glob to allow ~, prevent too long path, and prevent
 * perhaps running out of directories.

...

Looking at glob.c, there's no ~ nor 126/176/7e in the sources. Editing
the cont.a archive directly confirms no ~ or similar constant is
present.

By 2BSD, it was in sh.glob.c in the 'expand' function. Later versions
define TILDE as '~' and used that. V7 had no ~ in the shell, but as
you point out uucp there supported ~ for user home directories. V6
didn't have any of this included that I can find.


Warner

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

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

* Re: [TUHS] Where did the "~" come from
  2020-11-19  0:44   ` George Michaelson
  2020-11-19 13:45     ` Ron Natalie
@ 2020-11-19 16:16     ` Chet Ramey
  1 sibling, 0 replies; 9+ messages in thread
From: Chet Ramey @ 2020-11-19 16:16 UTC (permalink / raw)
  To: George Michaelson, Dave Horsfall; +Cc: The Eunuchs Hysterical Society

On 11/18/20 7:44 PM, George Michaelson wrote:
> A related but different "thing" is when the cd activity became a
> pushdown stack of 2 (is it more? I never bothered checking)
> 
> somebody realised going "there and back again" was innately useful.

It was definitely in ksh by 1986. It never made it into any of the Bourne
shells, but POSIX adopted it because it was in ksh88. I don't know
whether it was in the 1983 ksh version.

-- 
``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/

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

* Re: [TUHS] Where did the "~" come from
  2020-11-18 22:25 [TUHS] Where did the "~" come from Clem Cole
  2020-11-18 22:41 ` Dave Horsfall
  2020-11-19 15:50 ` Warner Losh
@ 2020-11-19 17:22 ` Mary Ann Horton
  2020-11-19 18:43   ` Clem Cole
  2 siblings, 1 reply; 9+ messages in thread
From: Mary Ann Horton @ 2020-11-19 17:22 UTC (permalink / raw)
  To: tuhs

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

I first saw ~ as part of csh. Bill had an adm3a at home (which is why 
HJKL in vi) but there was a variety of terminals at Berkeley. I assumed 
~ was Bill's idea.

     Mary Ann

On 11/18/20 2:25 PM, Clem Cole wrote:
> A couple of my friends from UC Berkeley were musing on another email 
> thread.   The question from one of them came up: /"I'm teaching the 
> undergrad OS course this semester  ... Mention where ~ comes."/
>
> This comment begets a discussion among the 4 of us at where it showed 
> up in the UNIX heritage and it if was taken from somewhere else.
>
> Using the tilde character as a short cut for $HOME was purely a 
> userspace convention and not part of the nami() kernel routine when it 
> came into being.  We know that it was supported by Mike Lesk in UUCP 
> and by Bill Joy in cshell.  The former was first widely released as 
> part of Seventh Edition but was working on V6 before that inside of 
> BTL.  Joy's cshell came out as part of 2BSD (which was V7 based), but 
> he had released "ashell" before that and included it in the original 
> BSD (/a.k.a./ 1BSD) which was for V6 [what I don't remember is if it 
> supported the convention and I can not easily un-ar(1) the 
> cont.a files in the 1BSD tar image in Warren's archives.
>
> In our exchange, someone observed suggested that Joy might have picked 
> it up because the HOME key was part of the tilde key on the ADM3A, 
> which were popular at UCB [/i.e./ the reason hjkl are the movement 
> keys on vi is the were embossed on the top of those keys on the 
> ADM3A].  It also was noted that the ASR-33 lacks a ~ key on its 
> keyboard.  But Lesk definitely needed something to represent a remote 
> user's home directory because each system was different, so he was 
> forced to use something.
>
> It was also noted that there was plenty of cross-pollination going on 
> as students and researchers moved from site to site, so it could have 
> been BTL to UCB, vice-versa, or some other path altogether.
>
> So two questions for this august body are:
>
>  1. Where did the ~ as $HOME convention come to UNIX?
>  2. Did UNIX create the idiom, or was there an earlier system such as
>     CTSS, TENEX, ITS, MTS, TSS, or the like supported it?
>

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

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

* Re: [TUHS] Where did the "~" come from
  2020-11-19 17:22 ` Mary Ann Horton
@ 2020-11-19 18:43   ` Clem Cole
  2020-11-19 20:02     ` Michael Kjörling
  0 siblings, 1 reply; 9+ messages in thread
From: Clem Cole @ 2020-11-19 18:43 UTC (permalink / raw)
  To: Mary Ann Horton; +Cc: TUHS main list

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

I had always thought that also until Pressotto pointed out the Lesk had
used it for UUCP which was running around Bell before Seventh Edition.  But
... given Bill talked about it for shell in his comments, as Warner points
out, that would have been before UUCP arrived at UCB -- so I don't think it
was from Lesk unless someone like Ken had mentioned it, or he knew about it
from another source (such as MTS from which Joy had learned/used as an
undergrad before UNIX).

As you said, Bill had an ADM3A at home (I had an H19 in those days), but as
you knew too well, there were a ton of different terminals at UCB --
whichever was cheapest usually had a run of popularity :-)  So the thought
HOME keycap = home directory also is quite possible.

Of course, Mike and Bill certainly could have come up with it
independently but to me, it seems like the chance of both using the same
char is really unlikely.   IIRC a tilde keycap was on the ASR-37 keyboard
but frankly, I don't remember, and can't find a pic of the keyboard detail,
plus the LCM+L is closed right now for CV-19 reasons so it's hard to check.



On Thu, Nov 19, 2020 at 12:23 PM Mary Ann Horton <mah@mhorton.net> wrote:

> I first saw ~ as part of csh. Bill had an adm3a at home (which is why HJKL
> in vi) but there was a variety of terminals at Berkeley. I assumed ~ was
> Bill's idea.
>
>     Mary Ann
> On 11/18/20 2:25 PM, Clem Cole wrote:
>
> A couple of my friends from UC Berkeley were musing on another email
> thread.    The question from one of them came up: *"I'm teaching the
> undergrad OS course this semester  ... Mention where ~ comes."*
>
> This comment begets a discussion among the 4 of us at where it showed up
> in the UNIX heritage and it if was taken from somewhere else.
>
> Using the tilde character as a short cut for $HOME was purely a userspace
> convention and not part of the nami() kernel routine when it came into
> being.  We know that it was supported by Mike Lesk in UUCP and by Bill Joy
> in cshell.  The former was first widely released as part of Seventh Edition
> but was working on V6 before that inside of BTL.  Joy's cshell came out as
> part of 2BSD (which was V7 based), but he had released "ashell" before that
> and included it in the original BSD (*a.k.a.* 1BSD) which was for V6
> [what I don't remember is if it supported the convention and I can not
> easily un-ar(1) the cont.a files in the 1BSD tar image in Warren's
> archives.
>
> In our exchange, someone observed suggested that Joy might have picked it
> up because the HOME key was part of the tilde key on the ADM3A, which were
> popular at UCB [*i.e.* the reason hjkl are the movement keys on vi is the
> were embossed on the top of those keys on the ADM3A].  It also was noted
> that the ASR-33 lacks a ~ key on its keyboard.  But Lesk definitely needed
> something to represent a remote user's home directory because each system
> was different, so he was forced to use something.
>
> It was also noted that there was plenty of cross-pollination going on as
> students and researchers moved from site to site, so it could have been BTL
> to UCB, vice-versa, or some other path altogether.
>
> So two questions for this august body are:
>
>    1. Where did the ~ as $HOME convention come to UNIX?
>    2. Did UNIX create the idiom, or was there an earlier system such as
>    CTSS, TENEX, ITS, MTS, TSS, or the like supported it?
>
>

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

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

* Re: [TUHS] Where did the "~" come from
  2020-11-19 18:43   ` Clem Cole
@ 2020-11-19 20:02     ` Michael Kjörling
  0 siblings, 0 replies; 9+ messages in thread
From: Michael Kjörling @ 2020-11-19 20:02 UTC (permalink / raw)
  To: tuhs

On 19 Nov 2020 13:43 -0500, from clemc@ccc.com (Clem Cole):
> IIRC a tilde keycap was on the ASR-37 keyboard
> but frankly, I don't remember, and can't find a pic of the keyboard detail,
> plus the LCM+L is closed right now for CV-19 reasons so it's hard to check.

http://www.navy-radio.com/manuals-ttycorp.htm#m37 has a copy of "37
KEYBOARD SEND-RECEIVE (KSR) TELETYPEWRITER SET AND 37 AUTOMATIC
SEND-RECEIVE (ASR) TELETYPEWRITER SET FOR "DATA-PHONE®" SERVICE
GENERAL DESCRIPTION AND OPERATION", issue 1, dated June 1971
<http://www.navy-radio.com/manuals/tty/m37/574-301-100-iss1-7106.pdf>
which on page 7 has a keyboard layout diagram. It looks to me like the
second right, topmost key, at least on the illustrated layout, came
with ^ ~ RS.

Also 574-321-800TC, "37 Keyboard (YK) and Base (YB) Parts" (issue 1,
December 1967, linked from that same page), page 9 indicates that for
this you'd want key cap part number 314843, which is listed as ~ RS ^.
Judging by that same page, it looks like P/N 313040 might also apply.

This isn't as good as an in-person look at an actual unit, of course,
but it definitely looks like you at least could have a key cap with a
tilde on the 37.

-- 
Michael Kjörling • https://michael.kjorling.se • michael@kjorling.se
 “Remember when, on the Internet, nobody cared that you were a dog?”


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

end of thread, other threads:[~2020-11-19 20:11 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-18 22:25 [TUHS] Where did the "~" come from Clem Cole
2020-11-18 22:41 ` Dave Horsfall
2020-11-19  0:44   ` George Michaelson
2020-11-19 13:45     ` Ron Natalie
2020-11-19 16:16     ` Chet Ramey
2020-11-19 15:50 ` Warner Losh
2020-11-19 17:22 ` Mary Ann Horton
2020-11-19 18:43   ` Clem Cole
2020-11-19 20:02     ` Michael Kjörling

The Unix Heritage Society mailing list

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://inbox.vuxu.org/tuhs

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V1 tuhs tuhs/ http://inbox.vuxu.org/tuhs \
		tuhs@minnie.tuhs.org
	public-inbox-index tuhs

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.vuxu.org/vuxu.archive.tuhs


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git