UNIPAK/UNIUNPAK by Douglas E. MacLean 2200 Ocean Avenue Apt. 6B Brooklyn, New York 11229 SysOp on the Vernon BBS (201) 827-6441 1200/2400 24 hours a day With the advent of the ZIP compression format, many programs will have to be modified to recognize both ARC and ZIP file formats. UNIPAK and UNIUNPAK are universal programs that will decide with format to use and call to correct program. For example: uniunpak -v qmail.qwk will view the files in the archive. If qmail.qwk was compressed with pkzip than the command executed will be: pkunzip -v qmail.qwk If the pkpak program was used the command executed would be pkunpak -v qmail.qwk All of this is transparent to the user. In a qmail reader, door or any program that uses archiving, substitute the universal command in the file that designates the compression program to use. You will than be able to unpack any type of file. Since the options for compression are more complicated that unpacking the UNIPAK program uses three environmental variables to permit the user the most control possible. If now extention (ARC or ZIP) is provided than the default will be to make a ZIP file. This can be overriden by the use of the UNIDEF environmental variable. set UNIDEF=arc will tell UNIPAK to default to ARC format if no file type is given in the filename. unipak -a source *.c will process all 'C' files into a compressed file named "source". If the UNIDEF variable was not set "source.zip" will be created. If the UNIDEF variable was set to arc as above the file created will be "source.arc". The zip format offers options to control the compression degree and the speed of the compression. These options can be set in UNIPAK by using the UNIBIN and UNIASC variables. UNIBIN controls the binary compression while the UNIASC variable controls the ascii compression. set UNIBIN=-eb4 set UNIASC=-ea4 This will tell UNIPAK to ZIP files using these compression parameters. The UNIUNPAK program will now take the default type from the UNIDEF variable. COmmands like: uniunpak test *.txt will extract the txt files from whatever type of file test is. If the wrong file type is given to a program it will attempt to determine the correct file type. For example, if an application forces the zip extent on a file name and you are trying to view the contents of the file test.arc the command unipak -v test.zip the UNIPAK program will look to see if test.zip exists. If it doesn't it will look for test.arc. If this is found the correct routine is called to list the files in test.arc.