implementation that can import from the local filesystem and from
https network sources. Normal paths, absolute and relative, are
imported from the local filesystem. Paths starting with a double-slash
(//) are imported as https URLs with an implicit https: prefix.
For example, the path
refers to the file grafana.libsonnet on the master branch of the
grafana/grafonnet-lib repository on GitHub (using the “raw” path to
retrieve the contents of the file instead of the GitHub web page for
The Importer has a SearchPath of type string that can be
populated directly or by using the AppendSearchFromEnv() method. The
method takes the name of an environment variable, splits it on the
OS-specific ListSeparator and appends the elements to the existing
The default Fetcher for the importer is the default http.Client,
which is used for importing URLs. It can be replaced with any type that
implements the Get method of http.Client. Most likely it will be
overridden with a http.Client that has been constructed with a
The importer maintains a cache of results as is required by the
jsonnet.Importer interface description. Positive and negative results
are cached and returned on subsequent calls to import the same path.
Errors retrieving a path are not cached and are returned as an error
results from the Import method.