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:
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.
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).
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.
Default origin when none is specified:
default_origin(Bundle,Origin) :- path_concat('github.com/ciao-lang',Bundle,Path), Origin=github(Path,master).