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.1 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HTML_MESSAGE,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 28133 invoked from network); 20 Jul 2020 17:46:20 -0000 Received: from minnie.tuhs.org (45.79.103.53) by inbox.vuxu.org with ESMTPUTF8; 20 Jul 2020 17:46:20 -0000 Received: by minnie.tuhs.org (Postfix, from userid 112) id 6EFE89BA55; Tue, 21 Jul 2020 03:46:11 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id AFCA29BA32; Tue, 21 Jul 2020 03:45:07 +1000 (AEST) Authentication-Results: minnie.tuhs.org; dkim=pass (1024-bit key; unprotected) header.d=ccc.com header.i=@ccc.com header.b="lrm9HfnO"; dkim-atps=neutral Received: by minnie.tuhs.org (Postfix, from userid 112) id D60C39BA32; Tue, 21 Jul 2020 03:45:04 +1000 (AEST) Received: from mail-qt1-f171.google.com (mail-qt1-f171.google.com [209.85.160.171]) by minnie.tuhs.org (Postfix) with ESMTPS id 96E849BA30 for ; Tue, 21 Jul 2020 03:45:03 +1000 (AEST) Received: by mail-qt1-f171.google.com with SMTP id 6so13825349qtt.0 for ; Mon, 20 Jul 2020 10:45:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ccc.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=bxZmQlbZY5whicaez3RZaJAC2n/XoRit01K1qLn648E=; b=lrm9HfnOWENVIXPayDoiKxw44OpA4p5DT++pHf5Hgrl+gC0S7PcSuD9rsPi19R60bA LO0o3rrpoIzTDwGZT1SKSqzipo3ee8dy3b0s89kN8Y/M+gD+vp181tA46wZRgGKJBa2x bAVkF9UwIMf/Lrwwo5+ETTcwULXTLsTKlIBvA= 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=bxZmQlbZY5whicaez3RZaJAC2n/XoRit01K1qLn648E=; b=Ydth1VH5/HYpGwfXwLCqF2F0yMD6kfrqqnJYINASOMWC8ACovDgHPsJSo6LEBgaFkk 9JPYRns2jZc0U4nXLr7l+jvK+TKmsX7NoBN0Czpf1a8D4cCWOpsf5t8M0fcbY2/Cb2LL oCHHBhcAwJA960YxuEnKO102j2juHKj+hk2pm4oNoruDGmoaA4JfEslnEVI7I13qjhJu DLkOPMR7FdXd/OpysLpKU4futThA8NY4ebgGyVdnbTLOqRnJlizYNKGlviyModS7JVcn +LDY64V4/TT7rTdqIqNsuQWFAADNENTvT9ADkbqKxj0i7oiczy/PpbVIahvvTLarWwhp UoTA== X-Gm-Message-State: AOAM532HPWPyJSoDb3IUQN2rkbo+bhEsdPRKyCBgbVMaua9cljaXYkJ4 oYJ/of4dwzh4uPO2f0PYrHzpO+R7vT8kKdCFStmoVA== X-Google-Smtp-Source: ABdhPJz6CpduhOqGbwDL5oOFaDObyDSmAE9ErPhr0OBKXUGpRhFvz3mVQxCugcmr6a2yrWzkmQ/qCwCPwnkBMg8tCDk= X-Received: by 2002:ac8:130d:: with SMTP id e13mr25234638qtj.253.1595267102239; Mon, 20 Jul 2020 10:45:02 -0700 (PDT) MIME-Version: 1.0 References: <78041442-c5e5-1b5c-8565-b6d31f23ec1b@gmail.com> In-Reply-To: <78041442-c5e5-1b5c-8565-b6d31f23ec1b@gmail.com> From: Clem Cole Date: Mon, 20 Jul 2020 13:44:35 -0400 Message-ID: To: Will Senn Content-Type: multipart/alternative; boundary="000000000000f3f6bf05aae3108e" Subject: Re: [TUHS] Traditional method of dealing with embedded shar files 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" --000000000000f3f6bf05aae3108e Content-Type: text/plain; charset="UTF-8" On Mon, Jul 20, 2020 at 1:25 PM Will Senn wrote: > As y'all know, I'm a relative latecomer to the world of Unix, but I do try > to figure out how y'all did it back when. So, sometimes, as in this case, I > can figure out how to do something, but I'm curious how it was done back in > the day, moreso than how I can get it done today. I'm looking at the > patching of my shiny new 2.11 BSD pl 431 system running on my speedy little > virtual PDP-11/70, so I grabbed patch 432 (here's a portion of the patch): > ... > To install the update cut where indicated below and save to a file > (/tmp/432) and then: > > cd /tmp > sh 432 > ./432.sh > ./432.rm > sh 432.shar > patch -p0 < 432.patch > > Watch carefully for any rejected parts of the patch. Failure of a > patch typically means the system was not current on all preceeding > updates _or_ that local modifications have been made. > ... > ====== cut here > #! /bin/sh > # This is a shell archive, meaning: > # 1. Remove everything above the #! /bin/sh line. > # 2. Save the resulting text in a file. > # 3. Execute the file with /bin/sh (not csh) to create: > # 432.rm > # 432.sh > # 432.shar > # 432.patch > ... > # End of shell archive > > This seems straightforward. Just follow the directions et voila magic > happens. > > My questions for y'all are how would you go about doing this? Use vi to > delete everything through the ==== cut here line? Use some combination of > standard unix tools to chop it up? What was your workflow for patching up > the system using these files? > > In my world, if I screw something up, it's 15 seconds to run a restore > script in my simh directory and I can try again, so my level of concern for > a mistake is pretty low. If I was doing this in 1980, on real hardware, I > would have had many concerns, as I'm sure some of y'all can remember, how > did you prepare and protect yourselves so a patch was successful. > > BTW, I thought .shar was an archive format, so when I saw the patch was a > shar file, I was worried it would be in some binary form, lo and behold, it > looks like text to me... not even b64. So much to learn, so little time. > > Thanks, > > Will > > -- > GPG Fingerprint: 68F4 B3BD 1730 555A 4462 7D45 3EAA 5B6D A982 BAAF > > --000000000000f3f6bf05aae3108e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Mon, Jul 20, 2020 at 1:25 PM Will Senn <= ;will.senn@gmail.com> wrote:<= br>
=20 =20 =20
As y'all know, I'm = a relative latecomer to the world of Unix, but I do try to figure out how y'all did it back when. So, sometimes, as in this case, I can figure out how to do something, but I'm curious how it was done back in the day, moreso than how I can get it done today. I'= m looking at the patching of my shiny new 2.11 BSD pl 431 system running on my speedy little virtual PDP-11/70, so I grabbed patch 432 (here's a portion of the patch):
...
=C2=A0=C2=A0=C2=A0 To install the update cut where indicated below an= d save to a file
=C2=A0=C2=A0=C2=A0 (/tmp/432) and then:

=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 cd /tmp
=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 sh 432
=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 ./432.sh
=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 ./432.rm
=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 sh 432.shar
=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 patch -p0 < 432.patch

=C2=A0=C2=A0=C2=A0 Watch carefully for any rejected parts of the patc= h.=C2=A0=C2=A0 Failure of a
=C2=A0=C2=A0=C2=A0 patch typically means the system was not current o= n all preceeding
=C2=A0=C2=A0=C2=A0 updates _or_ that local modifications have been ma= de.
...
=3D=3D=3D=3D=3D=3D cut here
#! /bin/sh
# This is a shell archive, meaning:
# 1. Remove everything above the #! /bin/sh line.
# 2. Save the resulting text in a file.
# 3. Execute the file with /bin/sh (not csh) to create:
#=C2=A0=C2=A0=C2=A0 432.rm
#=C2=A0=C2=A0=C2=A0 432.sh
#=C2=A0=C2=A0=C2=A0 432.shar
#=C2=A0=C2=A0=C2=A0 432.patch
...
#=C2=A0=C2=A0=C2=A0 End of shell archive

This seems straightforward. Just follow the directions et voila magic happens.

My questions for y'all are how would you go about doing this? Use vi to delete everything through the =3D=3D=3D=3D cut here line? Use s= ome combination of standard unix tools to chop it up? What was your workflow for patching up the system using these files?

In my world, if I screw something up, it's 15 seconds to run a restore script in my simh directory and I can try again, so my level of concern for a mistake is pretty low. If I was doing this in 1980, on real hardware, I would have had many concerns, as I'm sure some of y'all can remember, how did you prepare and protect yourselves so a patch was successful.

BTW, I thought .shar was an archive format, so when I saw the patch was a shar file, I was worried it would be in some binary form, lo and behold, it looks like text to me... not even b64. So much to learn, so little time.

Thanks,

Will
--=20
GPG Fingerprint: 68F4 B3BD 1730 555A 4462  7D45 3EAA 5B6D A982 BAAF
--000000000000f3f6bf05aae3108e--