Skip to main content
Version: Next

Package: Uninstall

Deletes a package in a connection and updates the package index.

Designation​

Name
pm.Uninstall
Aliases
Uninstall

Configuration​

Package (package)
Name of the package
Force deletion (force)
Forces the deletion of the package, if not set, the package is only marked as deprecated

Description​

The module first checks whether any other packages installed in the connection depend on the package to be deleted. To do so, it reads the index and evaluates the package dependencies of each package listed in the metadata variable. If any dependencies are found, the operation is aborted.

Dependency checks are skipped if the Index is not configured

If the Index is not configured, the package is deleted without checking whether other installed packages depend on it. This can break dependent packages.

Configure the Index before deleting packages to enable dependency checking.

If no dependencies were found, the next step deletes all contained objects or marks them as deprecated. Upon successful completion of this step, the entire package along with its remaining folder structure is deleted, and the package is removed from the index.

If issues occur while deleting individual objects, an error message is logged and the operation is aborted. The index remains unchanged, and the package's folder structure is preserved, containing only those objects that could not be deleted.

Examples​

Mark a package as deprecated. This moves the package to the designated folder (e.g., _DEPRECATED):

./b4A pm.Uninstall --package B4A.PM -C TEST-0001

Delete a package:

./b4A pm.Uninstall --package B4A.PM -C TEST-0001 --force