rez.bundle_context#
- rez.bundle_context.bundle_context(context, dest_dir, force=False, skip_non_relocatable=False, quiet=False, patch_libs=False, verbose=False)#
Bundle a context and its variants into a relocatable dir.
This creates a copy of a context with its variants retargeted to a local package repository containing only the variants the context uses. The generated file structure looks like so:
/dest_dir/ /context.rxt /packages/ /foo/1.1.1/package.py /...(payload)... /bah/4.5.6/package.py /...(payload)...
- Parameters:
context (ResolvedContext) – Context to bundle
dest_dir (str) – Destination directory. Must not exist.
force (bool) – If True, relocate package even if non-relocatable. Use at your own risk. Overrides skip_non_relocatable.
skip_non_relocatable (bool) – If True, leave non-relocatable packages unchanged. Normally this will raise a PackageCopyError.
quiet (bool) – Suppress all output
patch_libs (bool) – If True, modify libs and executables within the bundle to patch any references to external packages back to their equivalents within the bundle. See https://rez.readthedocs.io/en/stable/context_bundles.html#patching-libraries for more details on this.
verbose (bool) – Verbose mode (quiet will override)