Class: Toys::SourceSpec::Gem
Overview
A spec for a source located in a gem.
Beware that within the Toys::SourceSpec namespace, the name Gem
resolves to this class rather than to Ruby's ::Gem. Prefix references
to the latter with ::, as the project's style rules already require.
Defined in the toys-core gem
Instance Attribute Summary collapse
-
#default_confirm ⇒ nil, boolean
readonly
The default response for a confirmation prompt.
-
#name ⇒ String
readonly
The gem name.
-
#on_missing ⇒ nil, ...
readonly
What to do if the gem is not installed.
-
#path ⇒ String?
readonly
The path from the gem's toys directory, or
nilfor the entire toys directory. -
#toys_dir ⇒ String?
readonly
The name of the gem's toys directory, or
nilto use the default. -
#version ⇒ Array<String>
readonly
The version requirements.
Attributes inherited from Base
#context_directory, #source_name
Method Summary
Methods inherited from Base
Instance Attribute Details
#default_confirm ⇒ nil, boolean (readonly)
The default response for a confirmation prompt
318 319 320 |
# File 'core-docs/toys/source_spec.rb', line 318 def default_confirm @default_confirm end |
#name ⇒ String (readonly)
The gem name.
277 278 279 |
# File 'core-docs/toys/source_spec.rb', line 277 def name @name end |
#on_missing ⇒ nil, ... (readonly)
What to do if the gem is not installed.
310 311 312 |
# File 'core-docs/toys/source_spec.rb', line 310 def on_missing @on_missing end |
#path ⇒ String? (readonly)
The path from the gem's toys directory, or nil for the entire toys
directory.
293 294 295 |
# File 'core-docs/toys/source_spec.rb', line 293 def path @path end |
#toys_dir ⇒ String? (readonly)
The name of the gem's toys directory, or nil to use the default.
300 301 302 |
# File 'core-docs/toys/source_spec.rb', line 300 def toys_dir @toys_dir end |
#version ⇒ Array<String> (readonly)
The version requirements. Always an array, which is empty if any version is allowed.
285 286 287 |
# File 'core-docs/toys/source_spec.rb', line 285 def version @version end |