Class: Capistrano::Deploy::Dependencies
- Inherits:
-
Object
- Object
- Capistrano::Deploy::Dependencies
- Includes:
- Enumerable
- Defined in:
- lib/capistrano/recipes/deploy/dependencies.rb
Instance Attribute Summary collapse
-
#configuration ⇒ Object
readonly
Returns the value of attribute configuration.
Instance Method Summary collapse
- #check {|_self| ... } ⇒ Object
- #each ⇒ Object
-
#initialize(configuration) {|_self| ... } ⇒ Dependencies
constructor
A new instance of Dependencies.
- #local ⇒ Object
- #pass? ⇒ Boolean
- #remote ⇒ Object
Constructor Details
permalink #initialize(configuration) {|_self| ... } ⇒ Dependencies
Returns a new instance of Dependencies.
11 12 13 14 15 |
# File 'lib/capistrano/recipes/deploy/dependencies.rb', line 11 def initialize(configuration) @configuration = configuration @dependencies = [] yield self if block_given? end |
Instance Attribute Details
permalink #configuration ⇒ Object (readonly)
Returns the value of attribute configuration.
9 10 11 |
# File 'lib/capistrano/recipes/deploy/dependencies.rb', line 9 def configuration @configuration end |
Instance Method Details
permalink #check {|_self| ... } ⇒ Object
17 18 19 20 |
# File 'lib/capistrano/recipes/deploy/dependencies.rb', line 17 def check yield self self end |
permalink #each ⇒ Object
[View source]
34 35 36 37 |
# File 'lib/capistrano/recipes/deploy/dependencies.rb', line 34 def each @dependencies.each { |d| yield d } self end |
permalink #local ⇒ Object
[View source]
28 29 30 31 32 |
# File 'lib/capistrano/recipes/deploy/dependencies.rb', line 28 def local dep = LocalDependency.new(configuration) @dependencies << dep dep end |
permalink #pass? ⇒ Boolean
39 40 41 |
# File 'lib/capistrano/recipes/deploy/dependencies.rb', line 39 def pass? all? { |d| d.pass? } end |
permalink #remote ⇒ Object
[View source]
22 23 24 25 26 |
# File 'lib/capistrano/recipes/deploy/dependencies.rb', line 22 def remote dep = RemoteDependency.new(configuration) @dependencies << dep dep end |