Examples using BUNDLE
- Last Updated: February 11, 2026
- 3 minute read
- OpenEdge
- Version 13.0
- Documentation
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 in Windows.
Put a single file named foo.x in the bundle, as shown:
|
Or, put all encrypted source files in the current directory in the bundle, as shown:
|
Or, put some selected files (this, that, what) in the bundle, as shown:
|
You can also put the selections into a file, as shown:
|
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 xcode files in the current directory, this.x, that.x, and what.x.
Now you need to copy the bundle to some destination. You can use FTP, making sure that binary mode is in effect.
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 and that.x) and put them in specified directories, enter this command:
|
You can also put the selections into a file, as shown:
|
Once you have unbundled the files, they can be executed or compiled in OpenEdge.
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, as
shown:
|
Binary and ascii can be mixed in a bundle, as shown:
|
Since bundle always appends files to the end, multiple files with the same name might appear in a bundle, as shown:
|
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 then foo.p (binary) is unbundled overwriting the other foo.p. To unbundle both files, use a selection list to give each file a unique name or put each in a different directory, as shown:
|
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, as shown:
|
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.