THE EXPLORER'S GUIDE TO LHarc It sometimes seems that versions of LHarc proliferate like rabbits, while documentation, especially in English, is as rare as hen's teeth and what there is is neither up to date nor comprehensive. This guide attempts to throw some light on the subject and to provide a comprehensive guide to LHarc 2.01, now the most commonly available version, with additional information on the newest version 3.10 (junior). CONTENTS 1.0 BACKGROUND 2.0 VERSIONS 3.0 GETTING STARTED WITH VERSION 2.01 4.0 USING LHarc 2.01 5.0 PARAMETER USAGE 6.0 COMMANDS 7.0 TEMPORARY FILES 8.0 SHELLS AND COMMAND LINE INTERFACES 9.0 VERSION 2.20 and newer 1.0 BACKGROUND LHarc has its origins in the world of MSDOS and UNIX and has been ported to the ST by people like Jon Webb, Thomas Quester and Haruyasu Yoshizaki who have put their versions in the public domain. Files are compressed using the Lempel-ziv and Huffman algorithms which give it its name and file extender (lzh) The archives themselves are portable across platforms at least in principle; it is the archiving utility programmes that have to be ST specific. LHarc set out to produce more compact archives than ARC, at the expense of being slower. New versions of both have changed the picture to some extent; in particular, new versions of LHarc are much faster. In the PC world, and now in that of the ST, Zip is challenging LHarc's position; it is fast, compacts well and on the ST offers a user-friendly interface, allowing files for archiving or extraction to be picked from a list and repeat operations to be carried out without leaving the programme. 2.0 VERSIONS There are three compression algorithms in the LHarc family corresponding to three groups of programmes: identifying which you have is not always easy. 2.1 LARC This does not use huffman encoding hence the missing h; it produces larger files but packs and unpacks much faster than LHarc (only in versions <= 2.01). This method is used in PFXPAK, a shareware programme packer by Thomas Quester. The programme LARC itself is obsolete as LHarc 2.01 offers this compression method with the /l switch. 2.2 lh1 The original lh1 algorithm is used by Jon Webb's LHarc.PRG (current version, .51 or 0.6), a TOS programme which obligingly presents a list of commands with a command line at the bottom. The list is comparatively simple with only six switches:- ------------------------------------------------------------------------------ LHarc-ST, Archive utility, Version 0.51á, compiled on 17/11/89 at 15:12:58 Usage: LHarc command archive [filenames] < Commands > a - Add file(s) to archive p - Extract to printer m - Move file(s) to archive l/v - Short/Verbose list of archive e/x - Extract file(s) from archive d - Delete file(s) in archive i - Extract with inquiry r - Rename file in archive s - Extract to screen t - Test archive integrity < Switches > h - Hold after command b - Retain backup copy of archive o - Overwrite existing files n - No compression (store only) f - Floppy/TurboDos check off c - Add comments ------------------------------------------------------------------------------ Thomas Quester's LHarc.ttp version 1.316 is regarded as the definitive programme for the lh1 process. Its usage is similar to version 2.01. 2.3 lh5 The newer, faster lh5 algorithm is supported by Thomas Quester's 2.01, usually named LHarc.TTP or LHAR201?.TTP, currently at version l. This uses lh5 by default, but extracts either lh1 or larc without question and will pack them if the right switches are used. The newest arrival on the scene, in May 94, is Lharc 3.10 by Christian Grunenberg and others, based on 2.01l and using the same commands but with additional switches, the more extensive UNIX wildcards,a built in GEM- interface and self-extracting files! It is spectacularly faster. The following timings were for packing and unpacking the package of programm and text files, totalling 261772 bytes, by which LHarc 2.20 was distributed. Time mins:secs Pack Unpack Size ---------------------- STZIP("deflate best") 1:23 18 118763 LHarc 2.01 2:06 33 120925 LHarc 3.10 1:09 12 120901 Source files and the archive were both on a ramdisk and timings were taken from clicking ok from the command line or the STZIP screen using a desktop clock. Many of the new switches are about naming files and seem intended to cope with MiNT/ MultiTOS conventions. Some of the changes are drastic enough to make it inadvisable to use existing shells. Version 3.10 junior corrects a few bugs and adds some additional features. Anyway - use LHarc 3.10 and its built in GEM-interface! The remainder of the text is about using Version 2.01; variations for 2.20 and newer versions are appended at the end. 3.0 GETTING STARTED WITH VERSION 2.01 Documentation for this programme consists of a German manual (MAN.DEU) an English manual (MAN.ENG), not as comprehensive as MAN.DEU, the README and LIESMICH files containing installation instructions and the revision history and LHarc.DOC, a brief introduction in German. There is also ALGORITHM.DOC explaining the compression methods used. Like many PD authors Thomas Quester asks that his programme should always be distributed with documentation. He goes to greater lengths than most, distributing LHarc as a packed programme (using PFXPAK) with the manuals (MAN.DEU, or if you are very lucky MAN.ENG) appended in compressed form - a combination of packed file and archive. PD libraries and Bulletin Boards often break this up and distribute the files separately with or without the manual. I have never knowingly seen this file though I have a much larger one of the same kind which came with my registered version of PFXPAK. If your LHarc seems rather large it may be one of these compound files. It runs in the normal way as an archiving programme, but will put on screen the message: LHarc beinhaltet noch einige Dateien. Auspacken mit x -rm LHarc.TTP or LHarc k”nnte noch einige Dateien enthalten. Auspacken mit Paramter LHarc.TTP This means: LHarc contains some files. Unpack with x -rm LHarc.TTP meaning that the files can be unpacked, to the current directory, by giving LHarc its own name as a parameter. The LIESMICH or README file if you have it, contains instructions for producing a smaller, working copy of the programme alone without this message: however it is possible to delete the files still leaving the message, so nothing can be taken for granted. 4.0 USING LHarc 2.01 LHarc is a ttp programme, presenting that daunting empty parameter box when run from the desktop. It carries out one command at a time then exits. If you make a mistake you have to type the command again; it keeps no history of the commands given. No more than 38 characters may be typed on the command line. Long chains of switches or extended path names quickly eat this up. If you want to make repeated use of the programme, it is worth copying it to a ramdisk for faster operation, particularly if you have no hard drive: this will also enable you to keep data and archive disks in the floppy drive. It may be worthwhile creating the archive on ramdisk if yours is big enough, particularly if you are carrying out repeated alterations resulting in the archive being constantly updated. If no parameters are passed it displays the following on pressing : LHarc Version 2.01l (Atari ST) Copyright (c) Haruyasu Yoshizaki, 1988-89. Optimiert von Thomas Quester 1989-91 ================================================================ 03.07.91 === <<< High-performance file-compression program >>> =============================================================================== Aufruf: LHarc [] [{{/|-}{[-|+|2|