Bundle fetch

Author(s): Jose F. Morales.

This module implements support for fetching bundles and their dependencies from remote locations (e.g., the network).

The predicate bundle_fetch/2 fetches a bundle and its dependencies, as follows:

  • if the bundle is in a non-top workspace, stops fetching (and do not try to fetch dependencies)
  • if the bundle is missing, retreive and store it at the top workspace (see CIAOPATH environment)
  • if the bundle is in the top workspace, skips fetching
  • try fetch bundle dependencies

A fetched bundle is automatically marked to distinguish them from user bundles, which are manually written by the user. It is possible to fetch a user bundle, e.g., to retreive all their dependencies.

Fetched bundles can be removed with bundle_rm/1. Removing a user bundle is not allowed with bundle_rm/1 (it must be done manually).

The location and fetch protocol is automatically recognized based on bundle aliases. See bundle_src_origin/2 for translation from bundle aliases to recognized origins (e.g., ciao-lang.org/foo downloads and uncompress a git archive).

Usage and interface

Documentation on exports


Select the origin for the given bundle name


    Obtain the origin for a bundle (for fetching). Use the default origin if unknown (default_origin/2).


      Cleanup the bundle fetch state


        Given a URL-like BundleAlias, obtain its Origin term for fetch and the bundle name Name. Throws an exception if malformed and fails silently if it is not a URL-like alias.


        Fetch Bundle and all its dependencies. Fetched is the list of newly fetched bundles.

        No further documentation available for this predicate.

        Documentation on internals


        Default origin when none is specified:

        default_origin(Bundle,Origin) :-

          Documentation on imports

          This module has the following direct dependencies: