Unnecessary tar-compress-uuencodes

tp at mccall.com tp at mccall.com
Fri Jul 13 19:44:09 AEST 1990


In article <1990Jul13.022224.25441 at lth.se>, bengtl at maths.lth.se (Bengt Larsson) writes:
> In article <3124 at psueea.UUCP> kirkenda at eecs.UUCP (Steve Kirkendall) writes:
> 
> (a list of valid points concerning a "shar" program)
> 
>>Did I miss anything?  Did I get anything wrong?  Does anybody know of an
>>existing format that comes close to these specs?
> 
> Hmmm, one way to do it would be to write a little "unpacker" program (in C),
> and distribute it with the archive (in plain text).

It had better be a VERY portable program!

> Suggested format for archive: (borrowed heavily from VMS_SHAR, the "shar"
> program for VMS)

I agree that the VMS_SHARE format is quite good. However, the VMS_SHARE
format is self unpacking on VMS, just like a unix shar is on unix, with no
tools that are not part of the OS. The VMS_SHARE is a DCL command procedure
that contains a TPU program (TPU is the VMS programmable text editor) to
unpack the files. 

The problem with a C program, is that it is VERY hard to write a portable
program with no #ifdef's that will do the job. If you go this route, write
it strictly as a filter, and invoke it just like you do sed in current
shar's, with the <<'EOF' input specifier and the > redirection for output.
And for heaven's sake, ONLY WRITE ONE OF THEM, and use only one name for
it! Whatever you write, I have to recognize explicitly (I maintain a VMS
unshar program, and I'm not interested in making it into a full Bourne
shell.)

Perhaps this is overkill? Wouldn't it be possible to escape the most
troublesome characters in such a way that you could still use sed to unpack
it? Anyone currently unpacking unix shar's has already emulated sed to some
degree, adding a few more substitute commands couldn't be hard. I don't advocate using AWK, while there is a
VMS version, it is large and not widely installed. I suspect MSDOS or Amiga
sites would have similar problems. 

Final note about the other proposed format, DON'T mung spaces into tabs.
Some people don't use tabs. The goal should be to do as good a job as
possible in reproducing the exact file that was packed.
-- 
Terry Poot <tp at mccall.com>                The McCall Pattern Company
(uucp: ...!rutgers!ksuvax1!mccall!tp)     615 McCall Road
(800)255-2762, in KS (913)776-4041        Manhattan, KS 66502, USA



More information about the Alt.sources.d mailing list