Creates a new SourceFetchProblem
for the given source
and error
.
Creates a new SpecificGemNotFoundException
for a gem with the given name
and version
. Any errors
encountered when attempting to find the gem are also stored.
Creates a new SystemExitException
with the given exit_code
Creates a new UnsatisfiableDependencyError
for the unsatisfiable Gem::Resolver::DependencyRequest
dep
Create an indexer that will index the gems in directory
.
Constructs an Installer
instance that will install the gem located at gem
. options
is a Hash
with the following keys:
Where to put a bin wrapper if needed.
Whether or not development dependencies should be installed.
Use /usr/bin/env in bin wrappers.
Overrides all version checks and security policy checks, except for a signed-gems-only policy.
Format the executable the same as the Ruby executable. If your Ruby is ruby18, foo_exec will be installed as foo_exec18.
Don’t raise if a dependency is missing.
The directory to install the gem into.
Use the specified security policy. See Gem::Security
Indicate that the gem should be unpacked into the users personal gem directory.
Only validate dependencies against what is in the install_dir
Install wrappers if true, symlinks if false.
An Array of arguments to pass to the extension builder process. If not set, then Gem::Command.build_args
is used
Creates a new Gem::Package for the file at gem
. gem
can also be provided as an IO
object.
If gem
is an existing file in the old format a Gem::Package::Old
will be returned.
Create a Gem Package task library. Automatically define the gem if a block is given. If no block is supplied, then define
needs to be called to define the task.
Constructor. Takes a single argument which is to be treated like a hashtable, or defaults to ENV
, the system environment.
Initialize a remote fetcher using the source URI
and possible proxy information.
proxy
[String]: explicit specification of proxy; overrides any environment
variable setting
nil: respect environment variables (HTTP_PROXY, HTTP_PROXY_USER,
HTTP_PROXY_PASS)
:no_proxy
: ignore environment variables and _don’t_ use a proxy
dns
: An object to use for DNS resolution of the API endpoint.
By default, use Resolv::DNS.
headers
: A set of additional HTTP headers to be sent to the server when
fetching the gem.
Creates a RequestSet
for a list of Gem::Dependency
objects, deps
. You can then resolve
and install
the resolved list of dependencies.
nokogiri = Gem::Dependency.new 'nokogiri', '~> 1.6' pg = Gem::Dependency.new 'pg', '~> 0.14' set = Gem::RequestSet.new nokogiri, pg
Constructs a requirement from requirements
. Requirements can be Strings, Gem::Versions, or Arrays of those. nil
and duplicate requirements are ignored. An empty set of requirements
is the same as ">= 0"
.
Constructs a Version
from the version
string. A version string is a series of digits or ASCII letters separated by dots.
Create Resolver
object which will resolve the tree starting with needed
Dependency objects.
set
is an object that provides where to look for specifications to satisfy the Dependencies. This defaults to IndexSet
, which will query rubygems.org.
Creates a new Source
which will use the index located at uri
.
Creates a new SourceList