home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 17 / CD_ASCQ_17_101194.iso / dos / util / ain22 / ain.doc next >
Text File  |  1994-06-30  |  62KB  |  1,718 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.           AIN - A file compression and archivation utility set
  13.  
  14.  
  15.                               Version 2.2
  16.  
  17.  
  18.  
  19.  
  20.  
  21.                               User's guide
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.              Copyright (c) 1993-94 Transas Marine (UK) Ltd.
  33.                         Saint-Petersburg, Russia
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.                                  - 2 -
  62.  
  63.  
  64.  This document  presents the  detailed description  of new software for
  65.  IBM  personal   computers  and  compatibles,  dealing  with  the  file
  66.  compression and  archivation. The  software includes  a  full-featured
  67.  archiver AIN  version 2.2,  an extracting  utility AINEXT  and an EXE-
  68.  files compressor AINEXE.
  69.  
  70.  The compression/decompression  methods, used  in AIN  archiver, excels
  71.  noticeably those  used in  any well-known  archivers, such as ARJ, LHA
  72.  and PKZIP, in both the compression degree and the performance.
  73.  
  74.  AINEXE utility is useful for saving the disk space, due to its ability
  75.  to reduce the size of most large DOS executables 2 to 3 times, without
  76.  detriment to their work.
  77.  
  78.  THIS  SOFTWARE   AND   MANUAL   ARE   SOLD   "AS   IS"   AND   WITHOUT
  79.  WARRANTIES  AS   TO  PERFORMANCE   OF  MERCHANTABILITY  OR  ANY  OTHER
  80.  WARRANTIES WHETHER  EXPRESSED  OR  IMPLIED.  BECAUSE  OF  THE  VARIOUS
  81.  HARDWARE AND SOFTWARE ENVIRONMENTS INTO WHICH THIS PROGRAM MAY BE PUT,
  82.  NO WARRANTY OF FITNESS FOR A PARTICULAR PURPOSE IS OFFERED.  GOOD DATA
  83.  PROCESSING PROCEDURE  DICTATES THAT  ANY PROGRAM  BE THOROUGHLY TESTED
  84.  WITH NON-CRITICAL DATA BEFORE RELYING ON IT.  THE USER MUST ASSUME THE
  85.  ENTIRE RISK OF USING THE PROGRAM.  ANY LIABILITY OF THE SELLER WILL BE
  86.  LIMITED EXCLUSIVELY  TO PRODUCT  REPLACEMENT  OR  REFUND  OF  PURCHASE
  87.  PRICE.
  88.  
  89.  No  part   of  this   publication  may   be  reproduced,  transmitted,
  90.  transcribed, stored  in a  retrieval system,  or translated  into  any
  91.  other language  or computer  language in whole or in part, in any form
  92.  or by  any means,  whether it  be  electronic,  mechanical,  magnetic,
  93.  optical, manual or otherwise, without prior written consent of Transas
  94.  Marine (UK) LTD.
  95.  
  96.  AIN is  Shareware, and  if you use AIN regularly we strongly encourage
  97.  you to  register it. As shareware, AIN was distributed freely in order
  98.  to allow  people to  "test drive"  it. The  try-before-you-buy concept
  99.  allows users  to find  out which programs are useful before purchasing
  100.  them. If  a is  useful, please  support it  through registration. With
  101.  registration you  will receive  the latest version of the software and
  102.  update notices.  Also the  registered version do not display shareware
  103.  banner screen.  To register, print out the ORDER.TXT, and send a check
  104.  or money order.
  105.  
  106.  The software is produced and distributed by Transas Marine (UK) Ltd.
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.                                  - 3 -
  121.  
  122.  
  123.                                 CONTENTS
  124.  
  125.  
  126.  1. INTRODUCTION............................................4
  127.     1.1 Comparison with the analogs.........................4
  128.     1.2. Main features......................................7
  129.     1.3. Comparison with the prevoius versions..............9
  130.  2. AIN VERSION 2.2 ARCHIVER...............................10
  131.     2.1. Command line format...............................10
  132.     2.2. Commands of the archiver..........................12
  133.         2.2.1. A - add files to the archive................12
  134.         2.2.2. D - delete files from the archive...........13
  135.         2.2.3. E - extract files from the archive..........14
  136.         2.2.4. F - refresh obsolete files..................15
  137.         2.2.5. L - list the contents of the archive........15
  138.         2.2.6. M - move files to archive...................16
  139.         2.2.7. T - test the integrity of the archive.......16
  140.         2.2.8. U - update the archive......................17
  141.         2.2.9. V - list the contents the archive...........17
  142.         2.2.10. X - extract files using their pathnames....17
  143.         2.2.11. Y - rebuild the archive....................18
  144.     2.3. The switches of the archiver......................18
  145.         2.3.1. F - split the archive into fragments........19
  146.         2.3.2. H - display the help........................21
  147.         2.3.3. G - garble with password....................21
  148.         2.3.4. M - define the compression method...........23
  149.         2.3.5. O - specify the output directory............23
  150.         2.3.6. P - match file names use the full path......24
  151.         2.3.7. R - recurse the subdirectories..............24
  152.         2.3.8. S - set the date/time stamp of the archive..24
  153.         2.3.9. U - define the access speed.................25
  154.         2.3.10. W - specify the working directory..........26
  155.         2.3.11. X - exclude files from processing..........26
  156.         2.3.12. Y - reply Yes to the archiver's requests...26
  157.     2.4. The AIN_SW environment variable...................27
  158.  3. THE AINEXT UTILITY.....................................28
  159.  4. THE AINEXE UTILITY.....................................29
  160.  
  161.  
  162.  
  163.  
  164.  
  165.  
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.  
  176.  
  177.  
  178.  
  179.                                  - 4 -
  180.  
  181.  
  182.  1. INTRODUCTION
  183.  
  184.  
  185.  
  186.  1.1 Comparison with the analogs
  187.  
  188.  At present,  there  are  about  ten  archivers  for  the  IBM  PC  and
  189.  compatibles. They  differ one  from another by both their features and
  190.  the technical  characteristics (i.e.  the compression  ratio  and  the
  191.  performance). The leading place among them belongs, apparently, to ARJ
  192.  version 2.41 and PKZIP version 2.04.
  193.  
  194.  ARJ version  2.41 excels  all other  archivers in  the amount  of  the
  195.  features, but  its technical  characteristics are not as good as those
  196.  of PKZIP version 2.04.
  197.  
  198.  The main  trait of  PKZIP version  2.04 is the high performance. As to
  199.  the compression  ratio, this  archiver is,  at least,  as good  as ARJ
  200.  2.41.
  201.  
  202.  Transas Marine (UK) Ltd. proposes a new archiver, AIN version 2.2. The
  203.  main advantage  of this archiver is the highest compression degree. It
  204.  becomes especially  noticeable when an archive contains a set of files
  205.  of the  same type  (e. g.  the source texts of a program's modules, or
  206.  the financial  documents related  to  the  different  periods  of  the
  207.  activity of a company). In such case, the results shown by AIN version
  208.  2.2 are 1.5 to 2 times better than those shown by all other archivers.
  209.  In average, the advantage is as large as 10 to 20 percent.
  210.  
  211.  As to the performance, AIN version 2.2 excels ARJ version 2.41 as much
  212.  as 1.5 to 2 times, and PKZIP version 2.04 as much as 10 to 20 percent.
  213.  The technical characteristics of the best PC archivers are illustrated
  214.  by the  table 1  (that includes  also the  old AIN version 2.0 and the
  215.  popular LHA version 2.13).
  216.  
  217.  In respect  of its  features, AIN  version 2.2  is, in practice, is as
  218.  powerful as  ARJ version  2.41. Although  some rarely used features of
  219.  ARJ version  2.41 are  not available  with AIN  version 2.2, there are
  220.  some important  opportunities, provided  by AIN  version 2.2, that ARJ
  221.  version 2.41  does not support. For instance, AIN version 2.2 makes it
  222.  possible for  the user  to transform an archive, while copying it from
  223.  one disk  to another,  into a multi-volume archive (this can be useful
  224.  when it  is necessary  to place  an archive,  stored in the hard disk,
  225.  into a  number of  floppy disks).  AIN version  2.2 uses an encryption
  226.  method which  is much more reliable than that used by ARJ version 2.41
  227.  (where the  encryption only  comes to  the translation  by a password-
  228.  depending table). So, AIN version 2.2 is a quite competitive product.
  229.  
  230.  
  231.  
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.                                  - 5 -
  239.  
  240.  
  241.                                                                Table 1.
  242.  
  243.                    The best archivers for the IBM PC.
  244.  
  245.  Benchmarks were performed on a 33MHz AT-486.
  246.  
  247.       AIN........AIN   version 2.2
  248.       ARJ........ARJ   version 2.41
  249.       ZIP........PKZIP version 2.04c
  250.  
  251.  +----------------------------------------------------------+
  252.  |   Data   | Archiver | Compressed | Compression | Decompr.|
  253.  |   type   |  /method |    size    |  time       |   time  |
  254.  |----------+----------+------------+-------------+---------|
  255.  |          |  AIN /m1 |   62,382   |      6.2    |   13.1  |
  256.  |          |      /m2 |   63,012   |      5.5    |   13.5  |
  257.  | 75 files |      /m3 |   80,470   |      4.7    |   13.9  |
  258.  |          |----------+------------+-------------+---------|
  259.  |  *.ASM   |  ARJ /jm |   96,783   |     15.6    |   17.0  |
  260.  |          |      /m1 |   97,163   |     13.5    |   17.0  |
  261.  |   size   |      /m3 |  100,646   |     12.5    |   16.9  |
  262.  |          |----------+------------+-------------+---------|
  263.  | 303,924  |  ZIP /ex |   99,239   |      6.3    |   14.0  |
  264.  |          |      /en |   99,902   |      6.0    |   14.0  |
  265.  |          |      /es |  110,711   |      5.3    |   14.3  |
  266.  |----------+----------+------------+-------------+---------|
  267.  |          |  AIN /m1 |  328,023   |     26.6    |   53.5  |
  268.  |          |      /m2 |  330,187   |     25.0    |   57.0  |
  269.  | 279 files|      /m3 |  418,560   |     20.6    |   55.6  |
  270.  |          |----------+------------+-------------+---------|
  271.  |  *.PAS   |  ARJ /jm |  454,249   |     63.1    |   70.2  |
  272.  |          |      /m1 |  464,536   |     60.0    |   71.2  |
  273.  |   size   |      /m3 |  466,991   |     54.2    |   71.6  |
  274.  |          |----------+------------+-------------+---------|
  275.  | 1,943,552|  ZIP /ex |  462,849   |     34.4    |   54.4  |
  276.  |          |      /en |  464,437   |     32.6    |   55.5  |
  277.  |          |      /es |  530,389   |     29.1    |   56.3  |
  278.  |----------+----------+------------+-------------+---------|
  279.  |          |  AIN /m1 |  261,813   |     14.8    |   16.4  |
  280.  |          |      /m2 |  262,772   |     11.8    |   16.3  |
  281.  | 70 files |      /m3 |  307,826   |      8.7    |   16.9  |
  282.  |          |----------+------------+-------------+---------|
  283.  |  *.XL*   |  ARJ /jm |  312,471   |     31.9    |   20.8  |
  284.  |          |      /m1 |  312,511   |     26.0    |   20.9  |
  285.  |   size   |      /m3 |  329,194   |     20.5    |   20.8  |
  286.  |          |----------+------------+-------------+---------|
  287.  |  892,540 |  ZIP /ex |  314,166   |     14.4    |   16.1  |
  288.  |          |      /en |  314,907   |     12.8    |   17.3  |
  289.  |          |      /es |  346,874   |      9.3    |   18.0  |
  290.  +----------------------------------------------------------+
  291.  
  292.  
  293.  
  294.  
  295.  
  296.  
  297.                                  - 6 -
  298.  
  299.  
  300.  +----------------------------------------------------------+
  301.  |   Data   | Archiver | Compressed | Compression | Decompr.|
  302.  |   type   |  /method |    size    |  time       |   time  |
  303.  |----------+----------+------------+-------------+---------|
  304.  |          |  AIN /m1 |  459,520   |     16.8    |    8.8  |
  305.  |          |      /m2 |  459,814   |     13.8    |    8.8  |
  306.  | 15 files |      /m3 |  490,421   |      9.6    |    9.4  |
  307.  |          |----------+------------+-------------+---------|
  308.  |  *.PCX   |  ARJ /jm |  459.999   |     25.4    |   13.0  |
  309.  |          |      /m1 |  460,002   |     23.0    |   10.7  |
  310.  |   size   |      /m3 |  467,856   |     17.1    |   11.6  |
  311.  |          |----------+------------+-------------+---------|
  312.  |  815,004 |  ZIP /ex |  460,037   |     20.6    |    9.0  |
  313.  |          |      /en |  460,623   |     16.2    |    8.3  |
  314.  |          |      /es |  488,639   |     11.5    |    8.7  |
  315.  |----------+----------+------------+-------------+---------|
  316.  |          |  AIN /m1 |  164,833   |      6.9    |    5.0  |
  317.  |          |      /m2 |  164,923   |      6.2    |    5.0  |
  318.  | 11 files |      /m3 |  180,565   |      5.1    |    5.2  |
  319.  |          |----------+------------+-------------+---------|
  320.  |  *.EXE   |  ARJ /jm |  173,016   |     10.3    |    5.8  |
  321.  |          |      /m1 |  173,002   |      9.4    |    5.7  |
  322.  |   size   |      /m3 |  176,081   |      8.3    |    5.9  |
  323.  |          |----------+------------+-------------+---------|
  324.  |  362,528 |  ZIP /ex |  173,015   |      7.2    |    4.6  |
  325.  |          |      /en |  173,065   |      6.2    |    4.5  |
  326.  |          |      /es |  187,007   |      4.9    |    4.7  |
  327.  |----------+----------+------------+-------------+---------|
  328.  |          |  AIN /m1 |  155,384   |     10.5    |    6.3  |
  329.  |          |      /m2 |  156,657   |      8.8    |    6.6  |
  330.  | 10 files |      /m3 |  183,671   |      6.6    |    7.9  |
  331.  |          |----------+------------+-------------+---------|
  332.  |  *.DBF   |  ARJ /jm |  160,041   |     36.4    |    7.3  |
  333.  |          |      /m1 |  161,808   |     16.1    |    7.6  |
  334.  |   size   |      /m3 |  173,438   |     10.5    |    7.1  |
  335.  |          |----------+------------+-------------+---------|
  336.  |  703,914 |  ZIP /ex |  157,296   |     14.1    |    5.3  |
  337.  |          |      /en |  160,650   |      9.3    |    5.3  |
  338.  |          |      /es |  186,543   |      6.1    |    5.5  |
  339.  |----------+----------+------------+-------------+---------|
  340.  |          |  AIN /m1 |  203,088   |      9.3    |    3.8  |
  341.  |          |      /m2 |  204,541   |      8.1    |    3.7  |
  342.  |  1 file  |      /m3 |  250,541   |      5.8    |    4.4  |
  343.  |          |----------+------------+-------------+---------|
  344.  |  *.DOC   |  ARJ /jm |  206,720   |     16.7    |    5.0  |
  345.  |          |      /m1 |  206,804   |     15.0    |    4.6  |
  346.  |   size   |      /m3 |  223,074   |      9.6    |    4.8  |
  347.  |          |----------+------------+-------------+---------|
  348.  |  603,909 |  ZIP /ex |  203,164   |     14.9    |    3.9  |
  349.  |          |      /en |  205,807   |     10.4    |    4.1  |
  350.  |          |      /es |  253,969   |      7.0    |    4.6  |
  351.  +----------------------------------------------------------+
  352.  
  353.  
  354.  
  355.  
  356.                                  - 7 -
  357.  
  358.  
  359.  +----------------------------------------------------------+
  360.  |   Data   | Archiver | Compressed | Compression | Decompr.|
  361.  |   type   |  /method |    size    |  time       |   time  |
  362.  |----------+----------+------------+-------------+---------|
  363.  |          |  AIN /m1 |   74,184   |     19.6    |    6.1  |
  364.  |          |      /m2 |   77,375   |      7.6    |    6.4  |
  365.  | 20 files |      /m3 |   93,221   |      5.4    |    6.7  |
  366.  |          |----------+------------+-------------+---------|
  367.  |  *.BMP   |  ARJ /jm |   74,366   |     45.0    |    7.0  |
  368.  |          |      /m1 |   75,533   |     17.0    |    6.8  |
  369.  |   size   |      /m3 |   80,486   |      9.0    |    6.9  |
  370.  |          |----------+------------+-------------+---------|
  371.  |  393,352 |  ZIP /ex |   75,381   |     21.3    |    5.5  |
  372.  |          |      /en |   77,361   |     11.5    |    5.7  |
  373.  |          |      /es |   92,270   |      4.8    |    5.6  |
  374.  +----------------------------------------------------------+
  375.  
  376.  
  377.  1.2. Main features
  378.  
  379.  The AIN  version 2.2  archiver requires  Microsoft DOS  version 2.0 or
  380.  newer and provides the following functions:
  381.  
  382.     * Archivation of separate files, directories and entire subtrees of
  383.       the MS  DOS file system. The names, or the name templates, of the
  384.       files to  archivate, can  be submitted both from the command line
  385.       and a file.
  386.  
  387.     * Replacing, deleting  and adding  new files  to existing archives.
  388.       The refreshment of an archive can be made automatically.
  389.  
  390.     * Extraction of  separate files, directories and entire subtrees of
  391.       the MS  DOS file  system into a given directory. The archiver can
  392.       take (or  not take)  into account  the full  paths stored  in the
  393.       archive's table of contents. The names, or the name templates, of
  394.       the files to extract, can be submitted both from the command line
  395.       and a  file. Files   extracted  from an archive have the same DOS
  396.       attributes and  the date/time  stamp as the original files had at
  397.       the moment  they  were  archivated.  The  directories  needed  to
  398.       reproduce the paths of files are created automatically.
  399.  
  400.     * Choosing between  four methods of compression providing different
  401.       ratio and  performance. There are also three additional modes for
  402.       choosing between  the compression  ratio and the quickness of the
  403.       access to  the files  stored in  the archive,  so  that  archives
  404.       intended to  be used  mainly as  a whole  can be  compressed both
  405.       better and quicker.
  406.  
  407.     * Creating multi-volume  archives, i.  e. such  that are made up of
  408.       several files,  named volumes,  or fragments. Different fragments
  409.       of the  same archive  can have  different size  and be  placed on
  410.       different diskettes  (e. g.,  you  may  create  an  archive  with
  411.       fragments placed,  if necessary,  on both  diskettes of different
  412.       capacity  and   the  hard  disk).  An  archive  fragment  can  be
  413.  
  414.  
  415.                                  - 8 -
  416.  
  417.  
  418.       considered as  both a  separate archive  and a part of the larger
  419.       archive.
  420.  
  421.     * Changing the  properties of  existing archives,  such as the used
  422.       compression method,  fragmentation etc. The resulting archive can
  423.       either replace  the old  one, or  be stored  in another  drive or
  424.       directory (in this case, the source archive is left unchanged).
  425.  
  426.     * Getting the  list of contents of an archive. The list can include
  427.       either basic, or full path names of the archive members.
  428.  
  429.     * Checking the  integrity of  archives. This is the reliable way to
  430.       detect both  accidental (caused  by either  physical  defects  of
  431.       magnetic media  or hardware faults) and intentional errors in the
  432.       archive structure.
  433.  
  434.     * Archive encryption.  The contents  of  an  encrypted  archive  is
  435.       accessible only  after entering  the correct encryption password.
  436.       This is  the reliable  way to  protect data from the unauthorized
  437.       access.
  438.  
  439.  The mnemonic and sense of the commands provided by AIN version 2.2 are
  440.  generally the  same as  in other  modern archivers, so that it is easy
  441.  for the user to get started with AIN version 2.2.
  442.  
  443.  Like other  archivers, AIN  version 2.2 keeps the console report about
  444.  the process,  that includes  the name  of the file being processed and
  445.  the progress  indicator. But,  unlike other archivers, AIN version 2.2
  446.  provides also the total progress indicator reflecting the completeness
  447.  of the whole job.
  448.  
  449.  For looking through archives and extracting files, it is convenient to
  450.  use  the   AINEXT  utility,  which  is  duplicates  the  correspondent
  451.  functions of  the archiver.  AINEXT should  be used,  instead  of  AIN
  452.  version 2.2,  to pass  archives to  other organizations that might not
  453.  have AIN  version 2.2.  This allows both to save the disk space (since
  454.  AINEXT.EXE is  smaller than AIN.EXE) and to avoid violation of Transas
  455.  Marine (UK) Ltd. copyright.
  456.  
  457.  The AIN package includes also an EXE-files compressing utility, AINEXE
  458.  version 2.2.  Using of this utility allows to reduce 2 through 3 times
  459.  the size of large DOS executables (100K and more bytes). The effect is
  460.  less noticeable  for small EXE-files. The compressed executable can be
  461.  run the  same way  as the  original. But  EXE-files that  use overlays
  462.  cannot be executed after compression, and the utility warns about such
  463.  the situations.
  464.  
  465.  The AINEXE  version 2.2 utility is very effective when applied to EXE-
  466.  files obtained  with the  aid of such software development packages as
  467.  Clipper etc.
  468.  
  469.  The useful  side effect from using this utility is that the compressed
  470.  form of  an executable  is protected  from direct  modification of its
  471.  contents, so  it becomes  very difficult  both to change the text of a
  472.  program message  and to break a dynamic protection mechanism (if any).
  473.  
  474.  
  475.                                  - 9 -
  476.  
  477.  
  478.  Attempts to  change the  EXE-file contents  will make  it most  likely
  479.  unable to  be executed.  From the  other hand,  it is a very difficult
  480.  task, to  restore the  original form  of  the  executeble.  Note  that
  481.  AIN.EXE and AINEXE.EXE are already compressed.
  482.  
  483.  
  484.  1.3. Comparison with the prevoius versions
  485.  
  486.  The commands  and options  of AIN version 2.2 do not differ from those
  487.  of AIN versions 2.1 and 2.0.
  488.  
  489.  AIN version  2.2 excels previous version in the performance (see Table
  490.  1).
  491.  
  492.  AIN version  2.2 archive  format is  incompatible  with  that  of  AIN
  493.  version 2.0.
  494.  
  495.  
  496.  
  497.  
  498.  
  499.  
  500.  
  501.  
  502.  
  503.  
  504.  
  505.  
  506.  
  507.  
  508.  
  509.  
  510.  
  511.  
  512.  
  513.  
  514.  
  515.  
  516.  
  517.  
  518.  
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.                                  - 10 -
  535.  
  536.  
  537.  2. AIN VERSION 2.2 ARCHIVER
  538.  
  539.  
  540.  
  541.  2.1. Command line format
  542.  
  543.  The MS  DOS command  line to  invoke AIN version 2.2 has the following
  544.  format:
  545.  
  546.       AIN <command> [{/|-}<switch>...] <archive_name>[.AIN]
  547.       [<base_directory>\] [@<list_file_name> ! <file_name_template>
  548.       ...]
  549.  
  550.  where the traditional meta-symbols are used, so brackets '[]' indicate
  551.  optional items,  braces '{}'  indicate an  obligatory choice, vertical
  552.  line '|'  means "or",  ellipsis '...'  indicate optional repetition of
  553.  the previous syntactic item.
  554.  
  555.  Letters in upper and lower cases are equivalent; the only exception is
  556.  the value of the /G switch.
  557.  
  558.  The command  line begins  with the name of the program (AIN), followed
  559.  by a <command> letter which defines the function requested (e. g., A -
  560.  add files  to an archive, D - delete etc.). All commands are described
  561.  in the subsequent sections of this manual.
  562.  
  563.  Switches define  the modes of processing. A <switch> is spelled as one
  564.  of the characters of '/' (slash) or '-' (minus) followed by one or two
  565.  identifying characters.  Some of  the switches  can be  followed by  a
  566.  value, e. g.:
  567.  
  568.       AIN A /R /GBobby ARCHIVE
  569.  
  570.  where the  'R' switch  has no  value, and the 'G' switch has the value
  571.  'Bobby'.
  572.  
  573.  The command  can contain  any number of switches (including none). The
  574.  switches are described in the subsequent sections of this manual.
  575.  
  576.  Any correct  DOS file  name can  be used as the <archive name>, but if
  577.  the file  with that name already exists, it must be an AIN version 2.2
  578.  archive. If  the file  name extension  is omitted,  then it is assumed
  579.  that the  extension is  '.AIN'. So,  the command  in the  last example
  580.  refers to  the ARCHIVE.AIN  archive. To specify that the file name has
  581.  no extension,  attach the  period '.'  at the end of the file name. E.
  582.  g.:
  583.  
  584.       AIN M ARCHIVE. *.C
  585.  
  586.  refers to a file with the name 'ARCHIVE.' (with no extension).
  587.  
  588.  The <base  directory> is the directory, from which files to add to the
  589.  archive are  taken, or  to which  files extracted from the archive are
  590.  placed. E. g., the command
  591.  
  592.  
  593.                                  - 11 -
  594.  
  595.  
  596.       AIN A ARCHIVE \PROJECT\SOURCE\ *.C *.ASM
  597.  
  598.  puts into  the archive  all files  with the extensions '.C' and '.ASM'
  599.  being found in the directory '\PROJECT\SOURCE', and the command
  600.  
  601.       AIN E ARCHIVE C:
  602.  
  603.  extracts all the files from the archive and puts them into the current
  604.  directory of the drive 'C:'
  605.  
  606.  The <base  directory> must  end with  either  '\'  or  ':'  character,
  607.  otherwise it  will be  understood as  the  first  of  the  <file  name
  608.  templates>.  When   the  <base  directory>  is  omitted,  the  current
  609.  directory (of the current drive) is assumed.
  610.  
  611.  The <file name templates> refer to the files to process. In conformity
  612.  with MS  DOS traditions,  they can contain such wildcard characters as
  613.  '*' (asterisk)  and '?' (question sign) to define a set of file names.
  614.  E. g., the command
  615.  
  616.       AIN A ARCHIVE D*.PAS *.A??
  617.  
  618.  stores in  the archive  only files  whose names  either begin with the
  619.  letter 'D'  and have the '.PAS' extension, or have the extensions made
  620.  up exactly of three characters, the first of which is 'A'.
  621.  
  622.  The sequence  of file  names and  templates can  include references to
  623.  files,  containing   lists  of  file  names  or  templates.  Such  the
  624.  references are preceded with '@' (at) character. E. g., the command
  625.  
  626.       AIN D ARCHIVE PROG.EXE @LIST
  627.  
  628.  provided that the file LIST contain the line:
  629.  
  630.       PACK.COM *.BAT
  631.  
  632.  is equivalent to the command:
  633.  
  634.       AIN D ARCHIVE PROG.EXE PACK.COM *.BAT
  635.  
  636.  The list  file should  consist of  one or several lines containing any
  637.  number of file names or templates, separated with blanks.
  638.  
  639.  Characters '/' (slash) and '-' (minus), used as the switch tag, can be
  640.  (but is  not obliged  to be)  separated, with  an arbitrary  number of
  641.  blanks, from  the preceding  element of the command. Swiches can occur
  642.  in any position, e. g.:
  643.  
  644.       AIN/R U -S/GSTAR ARCHIVE -WC: *.C-M3
  645.  
  646.  One switch tag can be followed by several switch letters, but, in this
  647.  case, only  the last  switch of the sequence can have a value. So, the
  648.  command can be spelled as follows:
  649.  
  650.       AIN U -RSGSTAR ARCHIVE -WC: *.C-M3
  651.  
  652.  
  653.                                  - 12 -
  654.  
  655.  
  656.  Since the minus character has the special meaning, it is impossible to
  657.  use, as command parameters, file names containing this character.
  658.  
  659.  The execution of the archiver can be stopped at any moment by pressing
  660.  Ctrl-Break keys. If the modification of an archive is interrupted, the
  661.  modification is  canceled and  the archive  is left  in  the  original
  662.  state.
  663.  
  664.  
  665.  2.2. Commands of the archiver
  666.  
  667.  The AIN version 2.2 archiver allows the following commands:
  668.  
  669.     A - add new files to the archive and replace those existing;
  670.     D - delete files from the archive;
  671.     E - extract files from the archive;
  672.     F - refresh obsolete files;
  673.     L - display the list of contents of the archive;
  674.     M - move files to the archive;
  675.     T - test the integrity of the archive;
  676.     U - refresh obsolete files and add new files;
  677.     V - display the verbose list of contents of the archive;
  678.     X - extract files from the archive, using the full path;
  679.     Y - change the characteristics of the archive.
  680.  
  681.  See below for the detailed description of these commands.
  682.  
  683.  
  684.  2.2.1. A - add files to the archive
  685.  
  686.  The command "A" copies files to the archive. E. g., the command
  687.  
  688.       AIN A ARCHIVE \SOURCE\ *.PAS *.DOC
  689.  
  690.  copies, from  \SOURCE base  directory to  the archive ARCHIVE.AIN, all
  691.  files which names have the extensions ".PAS" and ".DOC".
  692.  
  693.  If there  is no  archive with the name specified by the command, it is
  694.  created. This is the usual way of the creating of archives.
  695.  
  696.  If the base directory is omitted, the current directory is used to get
  697.  to the files.
  698.  
  699.  If there  are no  file names in the command, all files (of the base or
  700.  current directory) are added. So, the command
  701.  
  702.       AIN A ARCHIVE
  703.  
  704.  copies all  files of  the current  directory. Note  that although  the
  705.  archive itself  is in the current directory, it is not included in the
  706.  process. Such  the bahaviour  is characteristic  of all the archiver's
  707.  commands.
  708.  
  709.  
  710.  
  711.  
  712.                                  - 13 -
  713.  
  714.  
  715.  If the command contains the /R switch, then all requested files of the
  716.  given directory  and its  subdirectories are copied to the archive. E.
  717.  g., the command
  718.  
  719.       AIN A /R ARCHIVE \PROJECT\ *.C *.H
  720.  
  721.  copies all  files with  the ".C" and ".H" names' extensions, contained
  722.  in  the   \PROJECT\  directory,   all  its  subdirectories  (including
  723.  subdirectories of the subdirectories etc.).
  724.  
  725.  The "A"  command makes  the archive  to remember  all the  information
  726.  about the  file path  available directly  from the command. E. g., the
  727.  command
  728.  
  729.       AIN A ARCHIVE C:DIR\  TEXT\FILE.DOC
  730.  
  731.  uses and stores the path constructed as C:DIR\TEXT\FILE.DOC; this name
  732.  will be displayed by "V" command.
  733.  
  734.  If a  file with  the same  name turns  to be  already existing  in the
  735.  archive, it  is replaced.  For the  identification be  correct, it  is
  736.  recommended to  replace files  when being in the same current disk and
  737.  directory. For  example, after  the following command sequence will be
  738.  executed:
  739.  
  740.       C:
  741.       AIN A ARCHIVE TEXT.DOC
  742.       D:
  743.       AIN A ARCHIVE C:TEXT.DOC
  744.  
  745.  the archive  will contain  two copies  of the  same file,  because the
  746.  first call  of the archiver leaves no information about the disk where
  747.  the file is taken from.
  748.  
  749.  When identifying,  the archiver builds the full path name of the file,
  750.  proceeding from  both the stored part of the path name and the current
  751.  DOS state.  Then it  compares the  resulting string with the full path
  752.  name of  the file being added. Therefore, files stored with their full
  753.  names are always identified correctly. It is recommended, however, act
  754.  in accordance with to the rule mentioned above.
  755.  
  756.  
  757.  2.2.2. D - delete files from the archive
  758.  
  759.  The "D" command deletes files from the archive. E. g., the command
  760.  
  761.       AIN D ARCHIVE *.PAS *.DOC
  762.  
  763.  deletes from  the archive  all  files  with  ".PAS"  and  ".DOC"  name
  764.  extensions.
  765.  
  766.  The base directory, if specified, is ignored.
  767.  
  768.  The aforesaid  command deletes  all files  with the  given extensions,
  769.  with no  attention to  their path  names (as  they are  stored in  the
  770.  
  771.  
  772.                                  - 14 -
  773.  
  774.  
  775.  archive). Use  the /P switch to make the archiver to take the paths in
  776.  account:
  777.  
  778.       AIN D /P ARCHIVE C:\SOURCE\PROG\*.PAS
  779.  
  780.  This  command   deletes  all   ".PAS"  files   stored  with  the  path
  781.  "C:\SOURCE\PROG". If the value of the switch /P is 1:
  782.  
  783.       AIN D /P1 ARCHIVE \S*.PAS
  784.  
  785.  the command  deletes files whose paths meet the given string template.
  786.  So, the files \SOURCE\TAX.PAS and \SRC\PROG\DISCO.PAS are deleted, but
  787.  the file DISCO.PAS is not.
  788.  
  789.  The archive size is decreased after deletion.
  790.  
  791.  
  792.  2.2.3. E - extract files from the archive
  793.  
  794.  The "E" command extracts files from the archive and writes them to the
  795.  base (if specified) or current directory, e. g.:
  796.  
  797.       AIN E ARCHIVE A:\SOURCE\ *.PAS *.DOC.
  798.  
  799.  All files  are placed  in the  same directory  with no regard to paths
  800.  stored in  the archive.  If the  base directory  does not exist, it is
  801.  created automatically. Files  extracted from the archive have the same
  802.  DOS attributes  and the  date/time stamp  as the original files had at
  803.  the moment they were archivated.
  804.  
  805.  The set of files involved in the process is determined as described in
  806.  2.2.2, but  if no  file name  or template is specified in the command,
  807.  all files are extracted. E. g., the command
  808.  
  809.       AIN E ARCHIVE
  810.  
  811.  copies all  files of  the archive  to the current directory. Files are
  812.  not deleted from the archive, so the archive does not change.
  813.  
  814.  If the file already exists in the target directory, the user is warned
  815.  and then  has to select one of the options: to overwrite the old file,
  816.  to cancel  the extraction  of the  file, to  place the file to another
  817.  directory and to stop the extraction. The conversation starts with the
  818.  following message:
  819.  
  820.       <File name> already exists
  821.       Date/time: file <date/time>, archive <date/time>
  822.       Overwrite? [Y/N/AY/AN/Q] _
  823.  
  824.  The user  should enter "Y" (yes) or "AY" (always yes) to overwrite the
  825.  old file  and "Q"  to stop the extraction. Having answered "N" (no) or
  826.  "AN" (always no), the user is requested again:
  827.  
  828.       Create the file in another directory? [Y/N/AY/AN/Q] _
  829.  
  830.  
  831.                                  - 15 -
  832.  
  833.  
  834.  Here, "N"  and "AN"  mean that  the user  do not  wish the  file to be
  835.  extracted. Entering "Y" or "AY", the user will be requested to specify
  836.  a directory.  The user  can edit  the string  using the "Backspace" or
  837.  "Arrow left"  keys. The  user the  editing of  the directory  name  is
  838.  finished, when  the "Enter"  key is  pressed. The  path  name  of  the
  839.  directory can  start with a drive letter (like in "A:\UNPACK"). If the
  840.  directory specified does not exist, it is created automatically.
  841.  
  842.  The answers  "always yes"  and "always  no" mean that if the situation
  843.  will repeat,  the answers  "yes" or  "no"  will  be  assumed  with  no
  844.  request, respectively.  So, if  the user  wishes not  to extract files
  845.  that exist already, he should reply "AN" twice.
  846.  
  847.  
  848.  2.2.4. F - refresh obsolete files
  849.  
  850.  The "F"  command refreshes  old files  stored in  the archive,  i.  e.
  851.  replaced them with their newer copies, if any. E. g., the command:
  852.  
  853.       AIN F ARCHIVE \SOURCE\ *.PAS *.DOC
  854.  
  855.  overwrites those  files "*.PAS"  and "*.DOC" of the archive, that have
  856.  an earlier  date/time stamp  in comparison  with  corresponding  files
  857.  found  outside,  i.  e.  files  that  have  changed  since  they  were
  858.  previously copied to the archive.
  859.  
  860.  If the  base directory  is not  specified, the  current  directory  is
  861.  assumed, as usual. If no file name or template is specified, all files
  862.  are checked.
  863.  
  864.  Note that  if the  /R switch  was used  when files  were added  to the
  865.  archive, it  most likely should be used again when refreshing. So, the
  866.  archive created with the command
  867.  
  868.       AIN A /R ARCHIVE \PROJECT\
  869.  
  870.  should be refreshed with the command
  871.  
  872.       AIN F /R ARCHIVE \PROJECT\
  873.  
  874.  If the  /R switch is omitted, only those files of the archives will be
  875.  refreshed, that correspond to files of the \PROJECT directory (without
  876.  the subdirectories).
  877.  
  878.  The identification  of files is the same as when files are replaced by
  879.  A command.
  880.  
  881.  
  882.  2.2.5. L - list the contents of the archive
  883.  
  884.  The "L"  command displays  the information about the archive contents.
  885.  E. g., the command
  886.  
  887.       AIN L ARCHIVE *.PAS *.DOC
  888.  
  889.  
  890.                                  - 16 -
  891.  
  892.  
  893.  displays the  information about  all files of the archive, whose names
  894.  have the extensions ".PAS" or ".DOC".
  895.  
  896.  The information  includes: the  name (without the path), the size, the
  897.  date and  the time of the last modification. The asterisk '*' appended
  898.  to the  file name  indicates that  there is only the first part of the
  899.  file in this fragment of the archive, and only the size of the part is
  900.  displayed. A  number following  the file  name indicates that there is
  901.  only a  continuation of  the file  in this fragment, starting from the
  902.  offset equal  to that number. The set of files involved in the process
  903.  is determined  as described  in 2.2.3, so, if no file name or template
  904.  is specified  in the  command, the  information  about  all  files  is
  905.  displayed.
  906.  
  907.  After all  the screen  lines are  filled  with  the  information,  the
  908.  archiver suspends the output and requests:
  909.  
  910.       Continue? [Y/AY/Q] _
  911.  
  912.  When the  user replies  "Y" or "AY", the output resumes until the next
  913.  portion of data fills the screen, "Q" stops the process. You may press
  914.  "Enter" instead of "Y".
  915.  
  916.  The user  can redirect the standard output to put the information into
  917.  a file, e. g.:
  918.  
  919.       AIN L ARCHIVE > ARCHIVE.LST
  920.  
  921.  This command creates ARCHIVE.LST file containing the information about
  922.  the archive contents.
  923.  
  924.  
  925.  2.2.6. M - move files to archive
  926.  
  927.  The effect  of the  "M" command  is the  same as  of the  "A" command,
  928.  except that  moving includes deletion of the files after adding to the
  929.  archive. Files are deleted only after updating of the whole archive is
  930.  finished, so any possibility of the loss of data would be eliminated.
  931.  
  932.  This command  is suitable  for saving  the space on a disk, e. g., the
  933.  command
  934.  
  935.       AIN M /R \PROJECT\ARC \PROJECT\
  936.  
  937.  moves to  the archive  all files  of the  \PROJECT directory  and  its
  938.  subdirectories. Later,  the files  can be  restored with the following
  939.  command:
  940.  
  941.       AIN X \PROJECT\ARC \PROJECT\
  942.  
  943.  
  944.  2.2.7. T - test the integrity of the archive
  945.  
  946.  The "T"  command checks  the  integrity  of  an  archive  (i.  e.  the
  947.  correctness of its structure), e. g.:
  948.  
  949.  
  950.                                  - 17 -
  951.  
  952.  
  953.       AIN T ARCHIVE
  954.  
  955.  Only the command letter and the name of an archive should be specified
  956.  in the command line; other arguments, if any, are ignored.
  957.  
  958.  Using of  this command  is the  reliable way to detect both accidental
  959.  (caused by  either physical  defects of  magnetic  media  or  hardware
  960.  faults) and intentional errors in the archive structure.
  961.  
  962.  The user  is informed  about errors  detected while checking paticular
  963.  files of  the archive.  Any attempt  to extract  such files  from  the
  964.  archive will fail. They can only be deleted with the "D" command.
  965.  
  966.  
  967.  2.2.8. U - update the archive
  968.  
  969.  The effect  of the  "U" command  is the  same as  of the  "A" command,
  970.  except that  only those  files can  be replaced,  that have an earlier
  971.  date/time stamp  in comparison with corresponding files found outside,
  972.  i. e. files that have changed since they were previously copied to the
  973.  archive. E. g., the command
  974.  
  975.       AIN U ARCHIVE
  976.  
  977.  replaces obsolete  files of  the archive  and adds  new files from the
  978.  current directory.
  979.  
  980.  
  981.  2.2.9. V - list the contents the archive
  982.  
  983.  The effect  of the  "V" command is similar to that of the "L" command,
  984.  except that the "V" command displays the file names with the paths. E.
  985.  g., if an archive was created with the following command:
  986.  
  987.       AIN M /R ARCHIVE C:\PROJECT\
  988.  
  989.  then, the command
  990.  
  991.       AIN V ARCHIVE
  992.  
  993.  displays the  list of  the full names of all the files of the \PROJECT
  994.  directory and its subdirectories.
  995.  
  996.  Note, that  the archive  keeps, as  a file  name, only the part of the
  997.  path that was available in the command line when the file was added to
  998.  the archive (see the "A" command description).
  999.  
  1000.  
  1001.  2.2.10. X - extract files using their pathnames
  1002.  
  1003.  The "X"  command extracts,  like  the  "E"  command,  files  from  the
  1004.  archive. The  difference is that the "X" command restores the paths to
  1005.  the files  extracted. E.  g., if a file was copied to the archive with
  1006.  the following command:
  1007.  
  1008.  
  1009.                                  - 18 -
  1010.  
  1011.  
  1012.       AIN M ARCHIVE C:\A\B\FILE.TXT
  1013.  
  1014.  then the command:
  1015.  
  1016.       AIN X ARCHIVE FILE.TXT
  1017.  
  1018.  extracts the file and puts it into the C:\A\B directory.
  1019.  
  1020.  If the directory needed does not exist, it is created automatically.
  1021.  
  1022.  The path to an extracted file is built as follows:
  1023.  
  1024.  If no base directory is specified in the command line, the path stored
  1025.  in the  archive is  used as  is. Otherwise,  the letter  of a disk (if
  1026.  stored with  the path)  is discarded  and the  rest of  the string  is
  1027.  appended to  the name  of the  base directory.  E. g.,  continuing the
  1028.  example, the command
  1029.  
  1030.       AIN X ARCHIVE A:DIR\  FILE.TXT
  1031.  
  1032.  puts the  extracted file  into the A:DIR\A\B directory (having created
  1033.  it first, if necessary).
  1034.  
  1035.  
  1036.  2.2.11. Y - rebuild the archive
  1037.  
  1038.  The "Y" command changes the characteristics of an archive (but not its
  1039.  contents), that  was previously  defined with the archiver's switches.
  1040.  E. g., the following command
  1041.  
  1042.       AIN Y ARCHIVE /M1 /GBobby
  1043.  
  1044.  rebuilds the  archive using  the maximal  compression (/M1 switch) and
  1045.  encrypts its  contents with  the password  "Bobby" (supposed  that the
  1046.  archive was not encrypted earlier).
  1047.  
  1048.  The /O  switch allows  to specify  a new  name for the rebuilt archive
  1049.  and, thereby,  preserve its  original state  associated with  the  old
  1050.  name. E. g., the command
  1051.  
  1052.       AIN Y C:ARCHIVE /OA: /F360
  1053.  
  1054.  copies the  archive from the C drive to the A drive, splitting it into
  1055.  fragments corresponding  to the  360K diskettes  capacity. The  source
  1056.  archive does not change.
  1057.  
  1058.  
  1059.  2.3. The switches of the archiver
  1060.  
  1061.  The mode of operation of the archiver is controlled with the following
  1062.  switches:
  1063.  
  1064.     F - split the archive into fragments;
  1065.     H - display an information about the archiver usage;
  1066.     G - encrypt the archive with a password;
  1067.  
  1068.  
  1069.                                  - 19 -
  1070.  
  1071.  
  1072.     M - define the compression method;
  1073.     O - specify the output directory;
  1074.     P - use full pathnames;
  1075.     R - recurse subdirectories;
  1076.     S - set the date/time stamp of the archive;
  1077.     U - define the access speed;
  1078.     W - specify the working directory;
  1079.     X - exclude files from processing;
  1080.     Y - assume Yes reply to the archiver's request.
  1081.  
  1082.  See below for the detailed description of these switches.
  1083.  
  1084.  
  1085.  2.3.1. F - split the archive into fragments
  1086.  
  1087.  The "F" switch is used to control the size of the archive's fragments.
  1088.  
  1089.  The AIN archives can be made up of one or more files, generally called
  1090.  fragments. When  an archive  is created, the name of the first archive
  1091.  fragment (that  can be  the whole archive) is specified in the command
  1092.  line. As  a rule,  the extension  of the archive's name is ".AIN". The
  1093.  names of  the subsequent  fragments (if any) automatically receive the
  1094.  extentions ".001", ".002" etc. E. g., the command
  1095.  
  1096.       AIN A /F100 ARCHIVE
  1097.  
  1098.  creates fragments  ARCHIVE.AIN, ARCHIVE.001, ARCHIVE.002 etc. The size
  1099.  of these  fragments does  not exceed  100K. The possible values of the
  1100.  "F" switch can be described as follows:
  1101.  
  1102.       F{<number>[K|M]|A]}
  1103.  
  1104.  where <number>  specifies the  (maximum)  size  of  the  fragment,  in
  1105.  kilobytes or  megabytes depending  on  the  letter  that  follows  the
  1106.  <number> ("K" or "M"). The "K" letter can be omitted, so, the switches
  1107.  
  1108.       /F50 or /F50K
  1109.  
  1110.  define the fragment size equal to 50 kilobytes, and the switch
  1111.  
  1112.       /F1.5M
  1113.  
  1114.  defines the size equal to 1 and a half megabytes.
  1115.  
  1116.  Values less than 10K are not allowed.
  1117.  
  1118.  If the  value of  the switch is "A", the fragment size is limited only
  1119.  to the  free space  of the  disk. This  is the  default value  of  the
  1120.  switch. E. g., the command
  1121.  
  1122.       AIN A A:ARCHIVE
  1123.  
  1124.  creates an  archive on the drive A with fragments filling all the free
  1125.  space of (each next) diskette.
  1126.  
  1127.  
  1128.                                  - 20 -
  1129.  
  1130.  
  1131.  If the value specified is greater than the free space of the disk, the
  1132.  fragment will  use all  the space;  the archiver  rejects disks having
  1133.  less than 10K of free space.
  1134.  
  1135.  If the  value corresponds  to one  of the  standard capacities  of the
  1136.  formatted floppy  disk (e. g. 360K), the fragment size will not exceed
  1137.  the maximal  amount of  the free space of such a disk (i. e. 352K, for
  1138.  instance). E. g., fragments created with the command
  1139.  
  1140.       AIN A /F720 ARCHIVE
  1141.  
  1142.  have their size gauged to go into standard 720K diskettes (i. e. equal
  1143.  to 713K), and those created with the command
  1144.  
  1145.            AIN A /F1.2 ARCHIVE
  1146.  
  1147.  will fit  into 1.2M  diskettes (the  size is 1,185K). The full list of
  1148.  the special  sizes is  the following:  160K, 180K,  320K, 360K,  720K,
  1149.  800K, 1.2M, 1.44M, 2.88M.
  1150.  
  1151.  To specify  one of these sizes in its literal meaning, use the leading
  1152.  zero, e. g.:
  1153.  
  1154.       AIN A /F0360 ARCHIVE
  1155.  
  1156.  The archiver  informs the user about having built a fragment, and then
  1157.  requests:
  1158.  
  1159.       Create next fragment in directory <dir>? [Y/N/AY/Q] _
  1160.  
  1161.  where <dir>  is the  path to  the directory  in  which  the  preceding
  1162.  fragment was  created. At  this moment,  the user can replace the disk
  1163.  (if necessary)  and press  "Y" or "AY" to continue. Pressing "Q" stops
  1164.  the process.  To change  the drive or directory, the user should press
  1165.  "N" and  specify the  drive and  the directory  for building  the next
  1166.  fragment.
  1167.  
  1168.  So, if  there are  no more  floppy disks  to normally proceed with the
  1169.  archiving, the user can place the remaining part of the archive on the
  1170.  hard disk.  It is  possible, in the future, to transfer that part onto
  1171.  diskettes, changing the fragment size, if necessary:
  1172.  
  1173.       AIN Y /OA: /FA C:ARCHIVE.003
  1174.  
  1175.  The request  about possible  changing the output directory will appear
  1176.  despite the  user having previously replied "AY", if the free space on
  1177.  the disk is exhausted.
  1178.  
  1179.  The user can, with the /YF switch, prevent the fragmentation requests,
  1180.  so that  all the  fragments would  be created automatically (as far as
  1181.  possible).
  1182.  
  1183.  Fragmentation can  arise both  when the  user creates new archives and
  1184.  when he modifies old ones, e. g., the command
  1185.  
  1186.  
  1187.                                  - 21 -
  1188.  
  1189.  
  1190.       AIN F /F360 ARCHIVE
  1191.  
  1192.  freshens the obsolete files and splits the archive into fragments.
  1193.  
  1194.  The user  can work  with an archive fragment the same way as it were a
  1195.  complete archive. E. g., the command
  1196.  
  1197.       AIN E ARCHIVE.002 *.PAS *.DOC
  1198.  
  1199.  extracts files  from the  third fragment  of the archive. However, the
  1200.  archiver allows,  when executing  a command  that does  not modify the
  1201.  archive, to  process the  fragments in  succession. For  instance,  to
  1202.  extract the  contents of  all the  fragments of an archive to the hard
  1203.  disk, the  user can  insert the  first diskette for the A drive, enter
  1204.  the command:
  1205.  
  1206.       AIN X A:ARCHIVE C:
  1207.  
  1208.  and then  reply to  the consequent  requests (having the next diskette
  1209.  inserted) that  are exactly  the same  as those  at the  next fragment
  1210.  creation.
  1211.  
  1212.  When  executing   commands  that  modify  the  archive,  the  archiver
  1213.  processes only the fragment specified. E. g., the command:
  1214.  
  1215.       AIN F ARCHIVE.001
  1216.  
  1217.  freshens the files of only the ARCHIVE.001 fragment.
  1218.  
  1219.  Only the last fragment of an archive can be splitted.
  1220.  
  1221.  
  1222.  2.3.2. H - display the help
  1223.  
  1224.  The effect  of calling  the archiver  with the  /H switch specified is
  1225.  displaying  the   detailed  information   about  this   program.   The
  1226.  information includes  a description of all the archiver's commands and
  1227.  switches as  well as  several examples of their usage. The traditional
  1228.  /? switch is also available and has the same meaning.
  1229.  
  1230.  Other switches and the command letter, if any, are ignored.
  1231.  
  1232.  After all  the screen  lines are  filled  with  the  information,  the
  1233.  archiver suspends  the output  and  requests  the  same  way  as  when
  1234.  executing the  "E" command. Pressing "Enter" is the most common way to
  1235.  proceed.
  1236.  
  1237.  The archiver  will also  help with its usage if it fails to understand
  1238.  the command specified.
  1239.  
  1240.  
  1241.  2.3.3. G - garble with password
  1242.  
  1243.  The "G"  switch allows  to have  all the  data stored  in  an  archive
  1244.  encrypted with a password. This switch can be specified along with any
  1245.  
  1246.  
  1247.                                  - 22 -
  1248.  
  1249.  
  1250.  archive-modifying command  (A, D,  F, M, U, Y). So, the encryption can
  1251.  take place  both when an archive is being created and when an existing
  1252.  archive is being modified, e. g., the command
  1253.  
  1254.       AIN D /GBobby ARCHIVE FILE.TXT
  1255.  
  1256.  deletes the  file specified  and encrypts  the rest  with the  "Bobby"
  1257.  password.
  1258.  
  1259.  Any time,  when an encrypted archive is accessed, the password must be
  1260.  specified having  exactly the  same  form  (taking  into  account  the
  1261.  difference between  the two  letter cases) it had when the archive was
  1262.  encrypted, e. g., the command
  1263.  
  1264.       AIN L /GBobby ARCHIVE
  1265.  
  1266.  displays the list the contents of the encrypted archive.
  1267.  
  1268.  If the "?" character is specified as the /G switch value, the password
  1269.  is  requested  later  and  it  is  not  displayed  when  entered  (all
  1270.  characters are  shown as quotes). The "Backspace" or "Arrow left" keys
  1271.  can be  used to edit the password. The user must press the "Enter" key
  1272.  to finish editing.
  1273.  
  1274.  If the  archive is encrypted but the /G switch is not specified or its
  1275.  value is wrong, the password will be requested the same way.
  1276.  
  1277.  To change  the password,  or to  cancel the  encryption,  specify  the
  1278.  switch value as follows:
  1279.  
  1280.       G{<old password>|?}=[<new password>|?]
  1281.  
  1282.  E. g., the command
  1283.  
  1284.       AIN Y /GBobby=hacker ARCHIVE
  1285.  
  1286.  changes existing password "Bobby" to "hacker", and the command
  1287.  
  1288.       AIN Y /Ghacker=  ARCHIVE
  1289.  
  1290.  turns the archive into the uncrypted one.
  1291.  
  1292.  Note, that  although the password is not stored in the archive (hence,
  1293.  if you  have forgotten the password, you may regard the information as
  1294.  lost), a  checksum, obtained from the password, is kept. This checksum
  1295.  is used  (and actually  can only be used) by the archiver to reject an
  1296.  incorrect password  and not  to attempt  to decrypt  the archive, that
  1297.  would otherwise lead to errors.
  1298.  
  1299.  The encryption algorithm is based on a random numbers generator having
  1300.  the period equal to 2.8e14. The problem of an unauthorized decryption,
  1301.  therefore, is  connected with  the examination  of that huge number of
  1302.  variants and  hardly can  be solved  (even with the aid of a computer)
  1303.  for a reasonable time. Thus, the encryption available with AIN version
  1304.  
  1305.  
  1306.                                  - 23 -
  1307.  
  1308.  
  1309.  2.2 is  the reliable way to protect your confidential information from
  1310.  an unauthorized access.
  1311.  
  1312.  
  1313.  2.3.4. M - define the compression method
  1314.  
  1315.  The "M"  switch allows to select one of the compression methods listed
  1316.  below:
  1317.  
  1318.     1 - maximal compression ratio, low performance;
  1319.     2 - normal compression (the default method);
  1320.     3 - fast compression, smaller ratio;
  1321.     4 - no compression.
  1322.  
  1323.  This switch  can be specified along with any archive-modifying command
  1324.  (A, D, F, M, U, Y). E. g., the command
  1325.  
  1326.       AIN A /M3 ARCHIVE
  1327.  
  1328.  creates the archive using the fast method.
  1329.  
  1330.  The value  of the /M switch is stored in the archive to be used as the
  1331.  default the next time the archive is modified. So, the command
  1332.  
  1333.       AIN F ARCHIVE
  1334.  
  1335.  freshens the  archive (created  with the  preceding comand)  using the
  1336.  same (fast) method, and the command
  1337.  
  1338.       AIN Y /M1 ARCHIVE
  1339.  
  1340.  recompresses the  whole  archive  using  the  method  of  the  maximum
  1341.  compression.
  1342.  
  1343.  
  1344.  2.3.5. O - specify the output directory
  1345.  
  1346.  The "O"  switch allows  to specify  the output  directory, i.  e.  the
  1347.  directory used  for storing  the archive modified by the command. This
  1348.  switch can  be specified  along with any archive-modifying command (A,
  1349.  D, F, M, U, Y). E. g., the command
  1350.  
  1351.       AIN Y /OA:\ /F360 C:ARCHIVE
  1352.  
  1353.  copies the archive from the C disk to a number of floppy disks.
  1354.  
  1355.  If the  /O switch is not specified, the old archive is replaced by the
  1356.  modified version. When creating an archive, the switch is ignored.
  1357.  
  1358.  The /O  switch is  most convenient for copying an archive to diskettes
  1359.  and possibly having it splitted into fragments.
  1360.  
  1361.  
  1362.  
  1363.  
  1364.  
  1365.                                  - 24 -
  1366.  
  1367.  
  1368.  2.3.6. P - match file names use the full path
  1369.  
  1370.  The "P"  switch informs  the archiver  that the  file  names  and  the
  1371.  templates specified  in the command should be understood as containing
  1372.  the path  indication. The  switch  is  used  with  the  commands  that
  1373.  manipulate files in the archive (D, E, L, V, X). E. g., the command:
  1374.  
  1375.       AIN D /P ARCHIVE *.PAS
  1376.  
  1377.  deletes from  the archive  only those  of the  ".PAS" files,  that are
  1378.  stored in the archive without path, as it is specified by the command.
  1379.  If the  /P switch were omitted from this command, all files having the
  1380.  ".PAS" extension would be deleted.
  1381.  
  1382.  The /P  switch is  implied if  the command  contains an  explicit path
  1383.  indication. Thus, the command
  1384.  
  1385.       AIN V /P ARCHIVE \SOURCE\*.PAS
  1386.  
  1387.  displays the  information about  the ".PAS" files stored as having the
  1388.  "\SOURCE\" path  and is  equivalent  to  that  having  the  /P  switch
  1389.  omitted.
  1390.  
  1391.  If the value "1" is specified with the /P switch, e. g, in
  1392.  
  1393.       AIN D /P1 ARCHIVE \S*.PAS
  1394.  
  1395.  the special  characters used  in a  file name template spread over the
  1396.  whole template  string, including the path. So, the template specified
  1397.  in the example matches to \SOURCE\TAX.PAS, \SRC\PROG\DISCO.PAS and not
  1398.  matches to DISCO.PAS.
  1399.  
  1400.  
  1401.  2.3.7. R - recurse the subdirectories
  1402.  
  1403.  The "R"  switch indicates  that the files to add to the archive should
  1404.  be looked  for in  all the  subdirectories of  the base  (or  current)
  1405.  directory. E. g ., the command
  1406.  
  1407.       AIN A /R ARCHIVE \PROJECT\  *.PAS
  1408.  
  1409.  copies to  the archive  all the  files,  with  the  extension  ".PAS",
  1410.  containing  in   the  \PROJECT   directory  as  well  as  in  all  its
  1411.  subdirectories. If  the /R  switch were omitted from the command, only
  1412.  the files of the base directory would be copied.
  1413.  
  1414.  The switch is used with the commands A, F, M, U.
  1415.  
  1416.  
  1417.  2.3.8. S - set the date/time stamp of the archive
  1418.  
  1419.  The "S"  switch changes  the date/time stamp of the archive so that it
  1420.  would be  the same  as that of the newest file stored in this archive.
  1421.  E. g., the command
  1422.  
  1423.  
  1424.                                  - 25 -
  1425.  
  1426.  
  1427.       AIN F /S ARCHIVE
  1428.  
  1429.  puts the archive's date/time stamp in dependence of that of the newest
  1430.  file the  archive contains.  Omitting the  /S switch  results  in  the
  1431.  archive having  its date  and time  referred to the last moment it was
  1432.  modified. The /S switch is used with any archive-modifying command (A,
  1433.  D, F, M, U, Y).
  1434.  
  1435.  
  1436.  2.3.9. U - define the access speed
  1437.  
  1438.  The "U"  switch allows to select one of the values of the speed of the
  1439.  access to the files stored in the archive:
  1440.  
  1441.     1 - slow access (default);
  1442.     2 - normal speed;
  1443.     3 - fast access.
  1444.  
  1445.  The archive access speed is the quickness of execution of the commands
  1446.  that replace  (A, D,  F, M, U) or extract (E, X) files of the archive.
  1447.  The actual  access speed  depends not  only on the value selected, but
  1448.  also on the relative size of the file being accessed as well as on its
  1449.  position within  the archive  (an access  to a  small file can require
  1450.  much time).  However, by requesting the slower access, the user allows
  1451.  the archiver  to  enhance  the  compression  provided  by  the  method
  1452.  selected with the /M switch (see 2.3.4).
  1453.  
  1454.  The /U switch can be used with any archive-modifying command (A, D, F,
  1455.  M, U, Y). E. g., the command
  1456.  
  1457.       AIN A /U3 ARCHIVE
  1458.  
  1459.  creates an archive that can be updated fast.
  1460.  
  1461.  The value  of the /U switch is stored in the archive to be used as the
  1462.  default the next time the archive is modified. E. g., the command
  1463.  
  1464.       AIN F ARCHIVE
  1465.  
  1466.  applied to  the archive  created by  the  preceding  command,  rapidly
  1467.  freshens (some of the files of) the archive, and the command:
  1468.  
  1469.       AIN Y /U1 ARCHIVE
  1470.  
  1471.  turns it  to be  updated for  a  longer  time  (but,  may  be,  better
  1472.  compressed).
  1473.  
  1474.  The enhancement  of the  compression quality  at the  expense  of  the
  1475.  access speed  is especially noticeable when a large number of files of
  1476.  the same type are stored in an archive.
  1477.  
  1478.  From the  other hand,  if the  files have essentially different types,
  1479.  the compression quality can fall.
  1480.  
  1481.  
  1482.  
  1483.                                  - 26 -
  1484.  
  1485.  
  1486.  2.3.10. W - specify the working directory
  1487.  
  1488.  The "W"  switch allows  to specify  a directory  for  temporary  files
  1489.  allocation. E. g., when executing the command
  1490.  
  1491.       AIN F /WC: A:ARCHIVE
  1492.  
  1493.  the archiver  will use the C: drive's current directory for allocation
  1494.  of the  temporary copy  of the  archive being  modified,  keeping  the
  1495.  original archive  unchanged until  the work  is complete  (to preserve
  1496.  data from  being destroyed due to a hardware fault). If the "W" switch
  1497.  is omitted,  the same  directory (of  the same  disk) is  used for the
  1498.  temorary files  allocation as that containing the source archive. This
  1499.  requires the sufficient space on the disk, otherwise the archiver will
  1500.  stop (having  the archive  left in  its original  state,  of  course).
  1501.  Hence, it is recommended to assign the working directory always to the
  1502.  hard disk  (or, at any rate, to another drive) when modifying archives
  1503.  stored on floppy disks.
  1504.  
  1505.  
  1506.  2.3.11. X - exclude files from processing
  1507.  
  1508.  The "X"  switch excludes  the files  specified from the processing. E.
  1509.  g.,
  1510.  
  1511.       AIN A ARCHIVE *.EXE /XNC*.* /XFC*.*
  1512.  
  1513.  copies into the archive all the ".EXE" files of the current directory,
  1514.  except those that have their names starting with either "NC" or "FC".
  1515.  
  1516.  The "X" switch can occur several times with any command that uses file
  1517.  specifications (A, D, E, F, L, M, U, V, X). The "P" switch (see 2.3.6)
  1518.  can affect  understanding of  the file  path/name templates. Thus, the
  1519.  command
  1520.  
  1521.       AIN V /X\PROJECT\*.PAS ARCHIVE
  1522.  
  1523.  displays  an  information  about  \PROJECT\SOURCE\DISCO.PAS,  and  the
  1524.  command
  1525.  
  1526.       AIN V /P1 /X\PROJECT\*.PAS ARCHIVE
  1527.  
  1528.  does not,  because, in  this case,  the file  name falls  under the /X
  1529.  switch's influence.
  1530.  
  1531.  
  1532.  2.3.12. Y - reply Yes to the archiver's requests
  1533.  
  1534.  The "Y"  switch allows  to automatically  reply "Yes"  to all  or  the
  1535.  certain requests by the archiver. The value associated with the switch
  1536.  specifies the particular request type:
  1537.  
  1538.     F - the request about moving on to the next fragment;
  1539.     O - the request to overwrite a file.
  1540.  
  1541.  
  1542.                                  - 27 -
  1543.  
  1544.  
  1545.  If no  value is  specified, all the types of requests are implied. For
  1546.  example:
  1547.  
  1548.       AIN A /F360 /YF ARCHIVE
  1549.  
  1550.  writes all  the archive  fragments onto the same disk with no requests
  1551.  to the user to insert the next diskette.
  1552.  
  1553.  
  1554.  2.4. The AIN_SW environment variable
  1555.  
  1556.  The AIN  version 2.2 archiver takes the switches both from the command
  1557.  line and  the special variable of the DOS environment. The last allows
  1558.  the user  to redefine  the defaults  related to  the  switches.  Thus,
  1559.  having the following line added to the AUTOEXEC.BAT file:
  1560.  
  1561.       SET AIN_SW=/M3/U3/WC:
  1562.  
  1563.  the user  forces the  archiver to  use the  specified  values  as  the
  1564.  defaults. Then,  if some  of these  switches will  be omitted  from  a
  1565.  command, the  switch value  will be taken from the AIN_SW variable. E.
  1566.  g., the command
  1567.  
  1568.       AIN A /U2 /R ARCHIVE
  1569.  
  1570.  is executed with the following switches: /U2 /R /M3 /WC:.
  1571.  
  1572.  In order  to avoid  failures due  to the  disk overflow when modifying
  1573.  archives stored  on diskettes,  it is  recommended to  have the AIN_SW
  1574.  variable keeping  at least  the /W  switch that  would be specifying a
  1575.  hard disk  directory to  contain temporary  files (like  that  in  the
  1576.  example above).
  1577.  
  1578.  
  1579.  
  1580.  
  1581.  
  1582.  
  1583.  
  1584.  
  1585.  
  1586.  
  1587.  
  1588.  
  1589.  
  1590.  
  1591.  
  1592.  
  1593.  
  1594.  
  1595.  
  1596.  
  1597.  
  1598.  
  1599.  
  1600.  
  1601.                                  - 28 -
  1602.  
  1603.  
  1604.  3. THE AINEXT UTILITY
  1605.  
  1606.  The AINEXT  utility allows  to view  and extract  the contents  of  an
  1607.  archive created  with AIN  version 2.2.  It is simply a version of the
  1608.  archiver having  the reduced command set to support only displaying of
  1609.  the information  about an  archive and  extracting files (E, L, V, X).
  1610.  The command line format is the same:
  1611.  
  1612.  AINEXT  <command>   [{/|-}<switch>...]  <archive   name>[.AIN]  [<base
  1613.  directory>\] [@<list file name>!<file name template>...]
  1614.  
  1615.  Only /G, /H, /P, /X and /Y switches can be used.
  1616.  
  1617.  Unlike  AIN  version  2.2,  the  AINEXT  utility  ignores  the  AIN_SW
  1618.  environment variable.
  1619.  
  1620.  The AINEXT utility supports fragmented archives.
  1621.  
  1622.  Examples:
  1623.  
  1624.       AINEXT E ARCHIVE
  1625.  
  1626.  extracts all files from the archive to the current directory;
  1627.  
  1628.       AINEXT X /X*.EXE /GBobby ARCHIVE A: P*.*
  1629.  
  1630.  extracts, with  the paths,  from the  password-protected archive,  all
  1631.  files whose  names begin  with "P"  and extensions are not ".EXE", and
  1632.  puts them into the A: drive's current directory;
  1633.  
  1634.       AINEXT V ARCHIVE > ARCHIVE.LST
  1635.  
  1636.  lists the archive's contents to the ARCHIVE.LST file.
  1637.  
  1638.  The AINEXT utility should be used, instead of AIN version 2.2, to pass
  1639.  archives to  other organizations  that might not have AIN version 2.2.
  1640.  This allows  both to  save the disk space (since AINEXE.EXE is smaller
  1641.  than AIN.EXE)  and to  avoid violation  of Transas  Marine  (UK)  Ltd.
  1642.  copyright.
  1643.  
  1644.  
  1645.  
  1646.  
  1647.  
  1648.  
  1649.  
  1650.  
  1651.  
  1652.  
  1653.  
  1654.  
  1655.  
  1656.  
  1657.  
  1658.  
  1659.  
  1660.                                  - 29 -
  1661.  
  1662.  
  1663.  4. THE AINEXE UTILITY
  1664.  
  1665.  The AINEXE  utility is an EXE-file compressor. It is useful for saving
  1666.  the disk  space, due  to its  ability to reduce the size of most large
  1667.  (100K and  more bytes) DOS executables 2 to 3 times, without detriment
  1668.  to their work. The effect is less noticeable for small EXE-files.
  1669.  
  1670.  The command line format is the following:
  1671.  
  1672.       AINEXE <file name>[.EXE]
  1673.  
  1674.  The original  file is  saved under  the ".OLD"  extension (the utility
  1675.  terminates if  such file  already exists); you may delete it after the
  1676.  packed EXE-file is tested.
  1677.  
  1678.  The AINEXE  version 2.2 utility is very effective when applied to EXE-
  1679.  files obtained  with the  aid of such software development packages as
  1680.  Clipper etc.
  1681.  
  1682.  The useful  side effect from using this utility is that the compressed
  1683.  form of  an executable  is protected  from direct  modification of its
  1684.  contents, so  it becomes  very difficult  both to change the text of a
  1685.  program message  and to break a dynamic protection mechanism (if any).
  1686.  Attempts to  change the  EXE-file contents  will make  it most  likely
  1687.  unable to  be executed.  From the  other hand,  it is a very difficult
  1688.  task, to  restore the  original form  of  the  executeble.  Note  that
  1689.  AIN.EXE and AINEXE.EXE are already compressed.
  1690.  
  1691.  The compressed executable can be run the same way as the original. But
  1692.  EXE-files that  use overlays cannot be executed after compression, and
  1693.  the utility warns about such the situation. Generally, if the EXE-file
  1694.  contains an  information attached  to its  loadable part,  the utility
  1695.  puts a warning message and then requests:
  1696.  
  1697.     1 - cancel the compression
  1698.     2 - attach the information to the compressed file
  1699.     3 - discard the information
  1700.  
  1701.  If "1"  is chosen,  the utility terminates leaving the EXE-file in its
  1702.  original  state;   "2"  forces   the  utility  to  simply  attach  the
  1703.  information at  the end  of the compressed part; "3" allows to discard
  1704.  the information.  The most probable types of an additional information
  1705.  are:
  1706.  
  1707.     * symbol tables used by debuggers; this information most likely can
  1708.       be discarded, if no further debugging is intended;
  1709.  
  1710.     * a  program's read-only  data; this must be, at least, attached to
  1711.       the compressed EXE;
  1712.  
  1713.     * overlaying  codes and  data; the  user should give up the idea to
  1714.       compress such a file.
  1715.  
  1716.  Being called  with either  /H or  /? switch,  the AINEXE  utility only
  1717.  displays a help.
  1718.