home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 11 Util
/
11-Util.zip
/
SHAR324X.ZIP
/
SHAR.MAN
< prev
Wrap
Text File
|
1990-05-21
|
7KB
|
181 lines
NAME
shar - create shell archives
SYNOPSIS
shar [ options ] [ file1 ... ]
shar -S [ options ]
DESCRIPTION
Shar 3.23 (or later) creates "shell archives" (or shar
files) which are in text format and can be mailed. These
files may be unpacked later by executing them with /bin/sh.
The resulting archive is sent to standard out unless the -o
option is given. A wide range of features provide extensive
flexibility in manufacuring shars and in specifying shar
"smartness." Archives may be "vanilla" or comprehensive.
OPTIONS
Options can be given in any order. Some options depend on
each other:
The -o option is required if the -l or -L option is used.
The -n option is required if the -a option is used.
The -x and -L option are incompatible.
See -V below.
-V Produce "vanilla" shars which rely only upon the
existence of sed and echo in the unsharing environment.
In addition, "if test" must also be supported if the -X
option is used. The -V silently disables options
offensive to the "network cop" (or "brown shirt"), but
does warn you if it is specified with -b, -C, -p or -M
(any of which does or might require uudecode or
compress in the unsharing environment).
-v Verbose OFF. Disables the inclusion of comments to be
output when the archive is unpacked.
-w Do NOT check with 'wc -c' after unpack. The default is
to check.
-n name
Name of archive to be included in the header of the
shar files. See the -a switch.
-a Allows automatic generation of headers:
Submitted-by: who@where
Archive-name: <name>/part##
The <name> must be given with the -n switch. If name
includes a '/' "/part" isn't used. Thus:
-n xyzzy produces:
xyzzy/part01
xyzzy/part02
-n xyzzy/patch produces:
xyzzy/patch01
xyzzy/patch02
-n xyzzy/patch01. produces:
xyzzy/patch01.01
xyzzy/patch01.02
The who@where can be explicitly stated with the -s
switch if the default isn't apropriate. Who@where is
essentially built as `whoami`@`uname`.
where@u-3p -s who@where
Override automatically determined submitter name.
-x Don't overwrite existing files. The unpack will check
for an existing file before unpacking a given file from
the archive.
-X Interactively overwrite existing files (DO NOT USE FOR
SHARS SUBMITTED TO THE NET).
-b Treat all files as binary, use uuencode prior to pack-
ing. This increases the size of the archive. The reci-
pient must have uudecode in order to unpack. (USE OF
UUENCODE IS NOT APPRECIATED BY MANY ON THE NET).
-t Treat all files as text (default).
-C Compress and uuencode all files prior to packing. The
recipient must have uudecode and uncompress in order to
unpack (USE OF UUENCODE AND COMPRESS IS NOT APPRECIATED
BY MANY ON THE NET).
-p Allow positional parameter options. The options "-b"
and "-t" and "-C" may be embedded, and files to the
right of the option will be processed in the specified
mode.
-M Mixed mode. Determine if the files are text or binary
and archive correctly. Files found to be binary are
uudecoded prior to packing (USE OF UUENCODE IS NOT
APPRECIATED BY MANY ON THE NET).
-P Use temporary files instead of pipes in the shar file.
-c Start the shar with a cut line. A line saying 'Cut
here' is placed at the start of each output file.
-f Restore by filename only, rather than path. This option
causes only file names to be used, which is useful when
building a shar from several directories, or another
directory.
-d XXX
Use XXX to delimit the files in the shar instead of
SHAR_EOF. This is for those who want to personalize
their shar files.
-o XXX
Save the archive to files XXX.01 thru XXX.nn instead of
standard out. Must be used when the -l or the -L
switches are used
-l XX
Limit the output file size to XXk bytes but don't split
input files.
-L XX
Limit output file size to XXk bytes and split files if
necessary. The archives created with this option must
be unpacked in correct order.
-S Read list of files to be packed from the standard input
rather than from the command line. Input must be in a
form similar to that generated by the find command, one
filename per line. This switch is especially useful
when the command line will not hold the list of files
to be packed. For example:
find . -type f -print | sort | shar -S -C -L50 -o /tmp/big
If -p is specified on the command line, then the
options "-b" and "-t" and "-C" may be included in the
standard input (on a line separate from filenames).
The maximum number of lines of standard input, file
names and options, may not exceed 1024.
EXAMPLES
shar *.c > cprog.shar # all C prog sources
shar -v *.[ch] > cprog.shar # non-verbose, .c and .h files
shar -b -l28 -oarc.sh *.arc # all binary .arc files, into
# files arc.sh.01 thru arc.sh.NN
shar -f /lcl/src/u*.c > u.sh # use only the filenames
WARNINGS
Use of the -b, -M or -C may slow the archive process consid-
erably, depending on the number of files.
Use of -X produces shars which WILL cause problems with many
unshar procedures. Use this feature only for archives to be
passed among agreeable parties. Certainly, -X is NOT for
shell archives which are to be submitted to Usenet. Usage
of -b or -C in net shars will cause you to be flamed off the
earth.
SEE ALSO
unshar(1)
DIAGNOSTICS
Error messages for illegal or incompatible options, for
non-regular, missing or inaccessible files or for (unlikely)
memory allocation failure.
AUTHORS
shar3 is a derived work based on the efforts of:
decvax!microsof!uw-beave!jim (James Gosling at CMU)
Michael A. Thompson, Dalhousie University, Halifax, N.S., Canada
davidsen@sixhub (Bill Davidsen)
rhg@CPS.COM (Richard H. Gumpertz)
colas@avahi.inria.fr (Colas Nahaboo)
dennis%nanovx@gatech.edu (Dennis Boylan)
wht%n4hgf@gatech.edu (Warren Tucker)
(other anonymous persons)
man pages:
jhd@irfu.se (Jan Dj{rv)