Progress
Developer’s Toolkit
Examples Using BUNDLE
The following synopsis shows how to use bundle and unbundle. This section assumes you have to transfer encrypted source files, which are binary files.
First you have to create a “bundle” file. To do this you specify the output file (that is, the bundle) and one or more input files (the encrypted source files). For these examples, the bundle file has a .bun extension and the encrypted source files have a .x extension. The bundle is created on UNIX, copied to Windows, and unbundled on Windows.
Put a single file named
foo.x
in the bundle:
Or put all encrypted source files in the current directory in the bundle:
Or put some selected files (this, that, what) in the bundle:
You can also put the selections into a file:
Note that files are always appended to the bundle, so you can incrementally add files to it. Thus, the above sequence created
xcode.bun
with this in it:foo.x
, all x-code files in the current directory,this.x
,that.x
, andwhat.x
.Now you need to copy the bundle to some destination. You can use FTP, making sure that binary mode is in effect; KERMIT, making sure that binary mode is in effect; or dd.
To see what is in the bundle, enter this command:
The unbundle program lists a short table of contents. To see a full table of contents, enter this command:
To unbundle everything in the bundle and put the files in the current directory, enter this command:
To unbundle selected files (
this.x
andthat.x
) and put them in specified directories, enter this command:
You can also put the selections into a file:
Once you have unbundled the files, they can be executed or compiled in Progress.
Text files can also be bundled. You can specify -ascii on the command line, thereby making ascii the default file type; or you can specify ascii after the filename in the selection list:
Binary and ascii can be mixed in a bundle:
Since bundle always appends files to the end, multiple files with the same name might appear in a bundle:
In this example, the filename
foo.p
appears twice and represents two different files. When unbundling this (with -all)foo.p
(ascii) is unbundled first and thenfoo.p
(binary) is unbundled overwriting the otherfoo.p
. To unbundle both files, use a selection list to give each file a unique name or put each in a different directory:
You can also use a selection list to skip over a file by directing it to the null device, as shown in the following UNIX example:
To help differentiate files with identical names, unbundle -full shows files’ input file specifications, modify dates, and sizes in bytes; the current directory when the bundle was created; and a time stamp showing when the files were bundled:
(The V0 denotes version 0 of the bundle record format. It allows backward compatibility should this format have to be changed.) You can use -select with -full to see information on selected file names.
NOTE: Binary dump and loads are dramatically faster. See the section on PROUTIL in the Progress Database Administration Guide and Reference for more information on binary dump and load.
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |