.\" $Id: nushar.man,v 1.10 2012/02/29 19:48:10 ksb Exp $ .\" by Ben Jackson .\" $Compile: Display%h .\" $Display: ${groff:-groff} -Tascii -man %f |${PAGER:-less} .\" $Display(*): ${groff:-groff} -T%s -man %f .\" $Install: %b -mDeinstall %o %f && cp %f $DESTDIR/usr/local/man/man1/nushar.1 .\" $Deinstall: ${rm-rm} -f $DESTDIR/usr/local/man/[cm]a[nt]1/nushar.1* .TH NUSHAR 1 LOCAL .SH NAME nushar - create self extracting shell archives .SH SYNOPSIS .ds PN "nushar \fI\*(PN\fP [\fB\-b\fP\fBc\fP\fBf\fP] [\fB\-B\fP\~\fIbinsize\fP] [\fB\-d\fP\~\fIdelimiter\fP] [\fB\-i\fP\~\fIinfile\fP] [\fB\-O\fP\~\fIdestdir\fP] [\fB\-p\fP\~\fIprefix\fP] [\fB\-t\fP\~\fIfinal_text\fP] [\fIfiles\fP] .br \fI\*(PN\fP [\fB\-b\fP\fBc\fP\fBf\fP] [\fB\-d\fP\~\fIdelimiter\fP] [\fB\-e\fP\~\fInn/mm\fP] [\fB\-i\fP\~\fIinfile\fP] [\fB\-o\fP\~\fIoutfile\fP] [\fB\-p\fP\~\fIprefix\fP] [\fB\-t\fP\~\fIfinal_text\fP] [\fIfiles\fP] .br \fI\*(PN\fP \fB\-h\fP .br \fI\*(PN\fP \fB\-V\fP .SH DESCRIPTION \fINushar\fP is the ultimate shell archiver. It can pack files, devices and named pipes (we don't pack sockets because there are no shell level commands to create them). Binary files are automatically uuencoded. You don't have to worry about directory creation (the necessary directories are created automatically). It can binpack all the files into multiple parts which can be extracted in any order (see \fB\-O\fP for more information). .SH OPTIONS This command reads the environment variable \fBNUSHAR\fP for options. .TP .BI \-b Flatten the directory tree by stripping everything up to and including the last `/' in the filenames. The resulting archive will extract its contents into the current directory. It will contain no directory creation commands. .TP .BI \-B binsize specify the target binsize of the shar files created when \fI\*(PN\fP is binpacking your input files for you. See \fB\-O\fP for more information. .TP .BI \-c generate code to check the sizes of extracted files by calling \fIwc\fP and comparing against the original size. .TP .BI \-d delimiter specify the here-document delimiter (default END_OF_FILE). If you aren't using a packing prefix (see \fB\-p\fP) and you have the string `END_OF_FILE' at the beginning of a line somewhere in your input files (for example, if you're including another \fI\*(PN\fP archive) you can use this to change the here-document delimiter (see the manual page for \fBsh\fP). .TP .BI \-e nn/mm specify part N of M total, if you are creating a multipart archive manually. The resulting archive peice will tell the user what part it is and will include code at the end to make sure that all parts are sucessfully extracted. .TP .BI \-f generate code to set the date and mode of the extracted files using \fItouch\fP. If the version of touch on the remote system doesn't support the extensions necessary for this, the extracting archive will silently skip this step. .TP .BI \-h print a help message. .TP .BI \-i infile specify a file with a list of files to shar, one file per line. This is especially useful with the output of \fIfind\fP with the \fB\-print\fP option. .TP .BI \-o outfile specify an output filename (default stdout) to send the result of a single-part archive to. .TP .BI \-O destdir specify the output directory for binpacked shar files. When operating in the binpacking mode, \fI\*(PN\fP wraps each of the source files in its piece of shell code, and then binpacks them to create the fewest archives it can without exceeding the target size (see the \fB\-B\fP option). Each archive part will have a few lines added at the top to create all the directories necessary to extract that part. This can cause the part to exceed the specified size if there are many small files from different directories in that shell part. The parts will be written into the directory specified by this option. Each of the parts will tell the user which part it is and check to see if all the parts have been extracted (as with the \fB\-e\fP option). .TP .BI \-p prefix specify a prefix for each line of the shar'd files in the archive. This allows you to add a ``placeholding'' character in the archive to prevent braindead \fBsh\fP implementations from dropping leading whitespace. .TP .BI \-t final_text specify a string of instructions to give the user when all of the parts have successfully extracted. This is useful for telling the recipient what to do with their new files, or how to compile them. Usually this just points to a README file that was just extracted. .TP .BI \-V show version information .\" .SH EXAMPLES .SH BUGS If there are many small files from different directories in a binpacked archive part, the archive size can exceed the specified part size when all the directory creation commands are added. .PP The path that is at the top of the archive \fI\*(PN\fP creates was constructed by finding all the commands that might be called from the archive on various UNIX systems and taking the union of all of the directories in which they were found. There is almost certainly a flavor of UNIX that doesn't have the commands the archive is expecting in the path it has specified. Since the archive just augments any existing path, most users will never notice. .SH AUTHORS Ben Jackson & Kevin Braunsdorf .br bj@cc.purdue.edu & ksb@cc.purdue.edu .br .SH "SEE ALSO" .hlm 0 find(1), sh(1), wc(1), touch(1), sharfilter(8)