All predicatesShow sourceinclude.pl -- Support :- include(File) from SWISH

This module allows SWISH programs to include other programs from the shared gitty store. It realises this using the following steps:

We allow for hierarchical and circular includes.

Source include(+File, +Options)
Include file at a specific version. Supported options:
version(Version)
Include version Version of File, where Version is a gitty commit of the file. This is the same as :- include(Version)., but more explicit.

If the same file is included at two places it is included at most once. Additionally

The envisioned model is that we can specify which version is, possibly indirectly, included by using directives like this:

:- include(File, [version(Hash)]).
Source include_data(+FileID, -URI, -Data)[private]
Fetch the data to be included and obtain the URI for it.
Source include_file_id(+FileIn, -FileID, +Options) is det[private]
Normalise an include file identifier and verify its safeness.
Source file_alias(+File, -Spec) is semidet[private]
Translate Alias/Name into Alias(Name) if Alias is known and Name is safe.
Source add_extension(+File, -FileExt) is det[private]
Add a file name extension to indicate this is a Prolog file.
Source prolog:xref_source_identifier(+Src, -Id) is semidet[multifile]
prolog:xref_open_source(+File, -Stream) is det[multifile]
prolog:xref_source_time(+File, -Modified) is det[multifile]
Map swish://file to a file from the gitty store.
Source prolog:xref_source_file(+Term, -Path, +Options)[multifile]
Deal with the above expansion for :- include(program) to support the cross-referencer.