Certain attributes are required on specific tags in an RSS
feed. If a feed is missing one of these attributes, a MissingAttributeError
is raised.
BasicSpecification
is an abstract class which implements some common code used by both Specification and StubSpecification.
The command manager registers and installs all the individual sub-commands supported by the gem command.
Extra commands can be provided by writing a rubygems_plugin.rb file in an installed gem. You should register your command against the Gem::CommandManager
instance, like this:
# file rubygems_plugin.rb require 'rubygems/command_manager' Gem::CommandManager.instance.register_command :edit
You should put the implementation of your command in rubygems/commands.
# file rubygems/commands/edit_command.rb class Gem::Commands::EditCommand < Gem::Command # ... end
See Gem::Command
for instructions on writing gem commands.
Raised when attempting to uninstall a gem that isn’t in GEM_HOME.
Potentially raised when a specification is validated.
Used to raise parsing and loading errors
Potentially raised when a specification is validated.
Raised when a gem dependencies file specifies a ruby version that does not match the current version.
Raised by Gem::Validator
when something is not right in a gem.
Raised to indicate that a system exit should occur with the specified exit_code
Raised by Resolver when a dependency requests a gem for which there is no spec.
Create a package based upon a Gem::Specification
. Gem packages, as well as zip files and tar/gzipped packages can be produced by this task.
In addition to the Rake targets generated by Rake::PackageTask, a Gem::PackageTask
will also generate the following tasks:
Create a RubyGems package with the given name and version.
Example using a Gem::Specification
:
require 'rubygems' require 'rubygems/package_task' spec = Gem::Specification.new do |s| s.summary = "Ruby based make-like utility." s.name = 'rake' s.version = PKG_VERSION s.requirements << 'none' s.files = PKG_FILES s.description = <<-EOF Rake is a Make-like program implemented in Ruby. Tasks and dependencies are specified in standard Ruby syntax. EOF end Gem::PackageTask.new(spec) do |pkg| pkg.need_zip = true pkg.need_tar = true end
Available list of platforms for targeting Gem installations.
See ‘gem help platform` for information on platform matching.
A Requirement
is a set of one or more version restrictions. It supports a few (=, !=, >, <, >=, <=, ~>
) different restriction operators.
See Gem::Version
for a description on how versions and requirements work together in RubyGems.