Dec 262017
 
McLean's convert ARC to ZIP v1.6 with TP source.
File A2Z16.ZIP from The Programmer’s Corner in
Category Utilities for DOS and Windows Machines
McLean’s convert ARC to ZIP v1.6 with TP source.
File Name File Size Zip Size Zip Type
A2Z.DOC 8955 3684 deflated
A2Z.EXE 32512 14654 deflated
A2Z.PAS 42858 10496 deflated

Download File A2Z16.ZIP Here

Contents of the A2Z.DOC file


A2Z - The Ultimate ARC/PAK to ZIP converter

version 1.6
3/10/89
by Ian McLean


Program description
-------------------
A2Z is an archive to zip conversion program. What does this mean? Well, it
will convert files with an ARC or PAK extention into equivelent ZIP files,
thus (usually) saving disk space. Here's some fun features to know and tell:

. Preserves original file date and time
. Converts ARC/PAKs inside other ARC/PAKs inside other ARC/PAKs, etc, etc,
until everything's a ZIP
. Nifty log file

And other features that will become apparant in the following documentation.

Calling syntax
--------------
Use this for reference, each parameter will be described in detail later:

A2Z [/A] [/B] [/C] [/Z] [/N] [/S=device] [/W=dir] [!filespec] [filespec]

/A Append to log file /C Enter configuration
/B Batch mode /Z Check ZIPs for internal files
/N No log file /S Status log device
/W Work directory

!filespec File path or path and name, search below this directory as well
filespec File path or path and name, search only this directory

The Log File
------------
A2Z keeps a log file. This log file is called A2Z.LOG and is put in whatever
directory is current when A2Z is invoked. Statistics of all files converted,
not converted, and any errors are kept in the log file for later reference.
When A2Z encounters an error, it will NOT pause, it will write it in the error
log. Normally, the log file is started anew each time you run A2Z. That is,
if it already exists, it is deleted. However, if you enter a /A parameter on
the command line, the log file is appended to if it exists. This is good for
resuming an interrupted conversion. You can supress the log file by entering
a /N on the command line.

The Work Directory
------------------
Normally, A2Z will make its work directories off of the directory it's working
on. This is fine, except under multitasking environments; where you'll want
to specify the work directory. SO, you can, in your environment, set the
variable A2ZWORK to point to a directory for A2Z to work in. Do it like so:

C:\> SET A2ZWORK=C:\WORK

A2Z will clean up any files it creates, so don't worry. If you don't feel
like setting an environment variable, you can type /W=[dir] on the command
line. If a /W parameter is present, it overrides any environment variable
that may be set.

Batch Mode
----------
When A2Z begins, it searches the disk to see how many files it has to convert.
Then it displays some information so you can make a guess as to how long the
conversion is going to take. It then pauses for you to press a key. If you
run A2Z in, say, your BBS's daily event file, you don't really want it to pause
for a key. So, if you enter a /B on the command line, A2Z will not wait for a
key to be pressed; it will begin converting immediatly.

Configuration
-------------
Entering /C on the command line causes A2Z to enter it's configuration mode.
Here you must enter the paths and filenames for programs A2Z calls. This is
pretty self-explanatory. The one thing you have to remember is to enter a
FULL path and filename specification. For example, PKXARC won't work, you'll
have to enter C:\UTIL\PKXARC.EXE. This can be a bit of a pain, but it's kinda
necessary. Here's what A2Z asks for:

Path to:
PKZIP PK Ware's ZIP program. Must be version 0.80, at least.
PKUNZIP PK Ware's UNZIP program. Must be at least version 0.80.
PKUNPAK PK Ware's unARC program. PKXARC won't work! You need at
least version 3.6.
PAK NoGate consulting's ephemeral ARC program. This adds a new
level of compression to normal ARCs

Compression levels:
This is the level of compression to force when converting to ZIPs.
4 is the highest compression and consequentially takes longer. 1 is the
lowest level of compression and is almost instantanious. ASCII is for
text files, binary is for program files.

When you're running the configuration, A2Z.EXE must be in the current
directory. You'll get an error message if it's not. The reason for this is
that A2Z writes the changes you make in configuration to it's program file.
I could have make A2Z look to see what directory it was found in, but this
would have required at least DOS 3.1, and I didn't want to restrict that much.

If any of the information A2Z has is invalid, it will give you a message
and enter the configuration again.

ZIPfile searching (/Z)
----------------------
Normally, A2Z will search and convert only ARC and PAK files. But, if you've
run a previous version of this program that didn't convert internal ARCs, you
probably have a few ZIP files on your drive with ARCs or PAKs in them. So, if
you enter a /Z parameter on the command line, A2Z will examine .ZIP files in
the directories you specify and see if they have anything inside them that
needs to be converted. Handy, eh? The /Z parameter does not override normal
conversion. A2Z will convert BOTH archives and, if needed, ZIPfiles with this
option.

The Status Log (/S)
-------------------
Status log is a nifty feature that makes calling A2Z from a bulleting board
system relatively easy. Here's what it does: If a user is online and your
dynamically converting to a ZIP file, you can keep him/her updated on what's
going on. Just add /S=COM1 (or /S=COM2, etc) to the command line and helpful
updates will be sent to the comm port. No path names are sent ever for
security reasons. Default for the status log is the device NUL.

Running A2Z
-----------
You can specify up to twenty directories and/or filenames to convert on the
command line. Some valid ones are:

C:\PAS all of directory C:\PAS
*.* all files in current directory
D:\*.ARC all files with extention ARC in directory D:\
THIS all files THIS.* in the current directory

If you enter an ! before the path name (E.g, !C:\), A2Z will also search all
directories off of the one you specified for files matching the ones you
specified. Here's some more examples:

!D:\ all files in all directories on drive D:
!D:\*.* same as above
!C:\PAS\*.ARC all ARC files in path C:\PAS and below
!E:\A*.* all files matching A*.* on drive E:

You may enter up to twenty of these on one command line, remember:

!C:\ !D:\ !E:\ all files on drives C:, D:, and E:

A2Z will ONLY work on files with an extention of ARC or PAK. If you specify
the /Z parameter, A2Z will also work on ZIP files. But you'll have to rename
files that are archives but don't have the ARC or PAK extentions. Sorry.

Interrupting conversion
-----------------------
With previous versions of A2Z you could just press Ctrl-Break anywhere in the
program and exit cleanly. Well, you can't anymore. The recursive nature of
the new conversion routines requires a little neater way of exiting. So, you
now have to press ESC to stop conversion. Don't be dismayed when you press ESC
and don't see anything happen - A2Z finishes the file it's on before stopping.
If you do press control break, nothing will happen. In a dire emergency, you
can reboot your computer when A2Z is running and no data will be lost. You
will, however, have to remove several temporary directories that A2Z creates.
They're called A2Z.$$$. Also check for a file with the extention A2B. That's
a backup A2Z makes of the current file being worked on.

Notes
-----
Here's a good rule of thumb: Find your biggest archive. Multiply it's unarced
size by three. Have that much free space on your drive. A2Z will, of course,
detect an error at any stage in the conversion process, so don't worry.

A2Z is public domain. I have included the main source code and the source
code for the interrupt handler. If you have any questions, contact me at:

Ian McLean Voice phone:
3365 Timber Lake Road (404) 428-7829
Kennesaw, GA
30144

I'm also available (usually) to do small systems programming on a contract
basis. [<--- Blatant plug]

Update history
--------------
1.0 Initial release
1.1 Fixed a few bugs, improved windowing routines
1.2 A2Z wouldn't keep the origional archive date; 1.2 fixes this.
1.3 Full error protection added, A2Z.LOG is now kept, output cleaned up.
1.5 Full code rewrite and probably the last version that will be released.
Major changes, addition of internal arc/pak conversion, improved logging,
zip file checking, lotsa new stuff. Read the docs for more details.
1.6 Nifty keen new features such as /S, /W, SET A2ZWORK=, and /N. Also
pretended to clean up the code.




 December 26, 2017  Add comments

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)