cancel
Showing results for 
Search instead for 
Did you mean: 

Zip utility

 
SOLVED
Go to solution
Mike R Smith
Frequent Advisor

Zip utility

I am running ZIP 2.2 on VMS 8.3 using an account that has all privs. I am trying to perform a zip of several files into one and delete the files that were zipped.

Initially I thought a zip/delete was the answer but then I realized I was reading the doc wrong. I then attempted the zip/move which still does not remove the source files. The zip works just so you know.

I would appreciate it if someone has the syntax for this. I am currently doing:

$ zip/batch='input_file /move filename.zip
7 REPLIES 7
Steven Schweda
Honored Contributor

Re: Zip utility

> I am running ZIP 2.2 [...]

Seriously? That's before my time, and
probably has all kinds of bugs which have
been fixed in the intervening decade.

> [...] The zip works just so you know.

Not really. Trust me.

"-m" or /MOVE should do the job. If you have
a problem with Zip 3.0 or later, please
re-complain.

http://www.info-zip.org/

Note: UnZip 6.0 is available, too.

Current versions offer large-file support,
faster I/O, bzip2 compression, fewer bugs,
...
Mike R Smith
Frequent Advisor

Re: Zip utility

I just got here 4 weeks ago, zip 2.2 is what was here when i walked in. Given time i could look into installing a new version but that would take time due to tight regulations on installing anything. Thanks for the reply.
Steven Schweda
Honored Contributor
Solution

Re: Zip utility

Hey, I might look into it, but the oldest
source kit I have is 2.3 (which has enough
bugs to satisfy almost anyone), and it dates
from 1999. I could try to locate the source
for 2.2, but that would take time, and if
you have tight regulations on installing
anything, then I assume that any fixes for
version 2.2 would be as unwelcome as a whole
new 3.0 (which I'd expect to work).

alp $ dg

Directory ALP$DKA0:[SMS.ZIPM]

A.TXT;1 1 25-JUN-2009 10:04:24.06 (RWED,RWED,RE,)
B.TXT;1 1 25-JUN-2009 10:04:29.08 (RWED,RWED,RE,)

Total of 2 files, 2 blocks.
alp $ zip3l -mV [-]zipm.zip *.*
adding: a.txt (stored 0%)
adding: b.txt (stored 0%)
alp $ dg
%DIRECT-W-NOFILES, no files found

alp $ zip3l -v
Copyright (c) 1990-2008 Info-ZIP - Type 'zip "-L"' for software license.
This is Zip 3.0 (July 5th 2008), by Info-ZIP.
Currently maintained by E. Gordon. Please send bug reports to
the authors using the web page at www.info-zip.org; see README for details.

Latest sources and executables are at ftp://ftp.info-zip.org/pub/infozip,
as of above date; see http://www.info-zip.org/ for other sites.

Compiled with DEC C V7.3-009 for OpenVMS (V7.3-2 Alpha) on Jul 6 2008.

Zip special compilation options:
USE_EF_UT_TIME (store Universal Time)
VMS_PK_EXTRA
BZIP2_SUPPORT (bzip2 library version 1.0.5, 10-Dec-2007)
bzip2 code and library copyright (c) Julian R Seward
(See the bzip2 license for terms of use)
SYMLINK_SUPPORT (symbolic links supported, if C RTL permits)
LARGE_FILE_SUPPORT (can read and write large files on file system)
ZIP64_SUPPORT (use Zip64 to store large files in archives)
[encryption, version 2.91 of 05 Jan 2007] (modified for Zip 3)

Encryption notice:
The encryption code of this program is not copyrighted and is
put in the public domain. It was originally written in Europe
and, to the best of our knowledge, can be freely distributed
in both source and object forms from any country, including
the USA under License Exception TSU of the U.S. Export
Administration Regulations (section 740.13(e)) of 6 June 2002.

Zip environment options:
ZIP_OPTS: [none]
ZIPOPT: [none]
alp $
Hoff
Honored Contributor

Re: Zip utility

Move to current zip, and try it there. (2.2 is from around 1997 or so, and it features a wealth of known OpenVMS bugs, and I'd definitely expect it won't deal at all well with ODS-5 disks and extended file names.)

As for syntax with most of these sorts of Unix-style commands, I usually try something like:

zip -h

or

zip -?

In the case of zip, the qualifier -h is available.

FWIW, the OpenVMS port of zip and of unzip do offer DCL-style syntax, but (given my use of zip and unzip all over the place) I tend to prefer use of the foreign-command syntax.

If you can't get off of zip 2.2 and for whatever justification is used to trump the "we're still on v.ancient" and "well then upgrade to current" discussion (and I really don't care why that's the case), then (here) use a DELETE command after the zip and move on to the next problem.

The OpenVMS FAQ http://www.hoffmanlabs.com/vmsfaq has some information on locating various tools including pointers over to sites with zip and unzip. (Though Steven has already provided these.)

And if you're zipping OpenVMS files, always use the "-V" option as this preserves the OpenVMS file metadata.

Stephen Hoffman
HoffmanLabs LLC
Steven Schweda
Honored Contributor

Re: Zip utility

> In the case of zip, the qualifier -h is
> available.

And, nowadays, "-h2" (/HELP = EXTENDED), if
you need reading material and can't find
"zip.txt".

> And if you're zipping OpenVMS files, always
> use the "-V" option as this preserves the
> OpenVMS file metadata.

Always, unless you plan to take the archive
to a non-VMS system, and you're using a Zip
older than 2.31 (May 2000). (Just one of
those many bugs...)


On the bright side, even the CLI "/MOVE"
qualifier works these days:

alp $ dg

Directory ALP$DKA0:[SMS.ZIPM]

A.TXT;1 1 25-JUN-2009 10:44:53.62 (RWED,RWED,RE,)
B.TXT;1 1 25-JUN-2009 10:44:58.95 (RWED,RWED,RE,)

Total of 2 files, 2 blocks.

alp $ zip_cli3l /move /vms [-]zipm.zip *.*
updating: a.txt (stored 0%)
updating: b.txt (stored 0%)

alp $ dg
%DIRECT-W-NOFILES, no files found

alp $ zip_cli3l /verbose
Copyright (c) 1990-2008 Info-ZIP - Type 'zip "-L"' for software license.
This is Zip 3.0 (July 5th 2008), by Info-ZIP.
Currently maintained by E. Gordon. Please send bug reports to
the authors using the web page at www.info-zip.org; see README for details.

Latest sources and executables are at ftp://ftp.info-zip.org/pub/infozip,
as of above date; see http://www.info-zip.org/ for other sites.

Compiled with DEC C V7.3-009 for OpenVMS (V7.3-2 Alpha) on Jul 6 2008.

Zip special compilation options:
USE_EF_UT_TIME (store Universal Time)
VMSCLI
VMS_PK_EXTRA
BZIP2_SUPPORT (bzip2 library version 1.0.5, 10-Dec-2007)
bzip2 code and library copyright (c) Julian R Seward
(See the bzip2 license for terms of use)
SYMLINK_SUPPORT (symbolic links supported, if C RTL permits)
LARGE_FILE_SUPPORT (can read and write large files on file system)
ZIP64_SUPPORT (use Zip64 to store large files in archives)
[encryption, version 2.91 of 05 Jan 2007] (modified for Zip 3)

Encryption notice:
The encryption code of this program is not copyrighted and is
put in the public domain. It was originally written in Europe
and, to the best of our knowledge, can be freely distributed
in both source and object forms from any country, including
the USA under License Exception TSU of the U.S. Export
Administration Regulations (section 740.13(e)) of 6 June 2002.

Zip environment options:
ZIP_OPTS: [none]
ZIPOPT: [none]
alp $


But if you like 2.2 better, it's ok with me.
(If a man wants to carry a cat by its tail, I
say, "Let him.")