Class: Cape::CapistranoDeprecated Private
- Inherits:
-
Capistrano
- Object
- Capistrano
- Cape::CapistranoDeprecated
- Defined in:
- lib/cape/capistrano_deprecated.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Implements Capistrano with deprecated methods.
Instance Attribute Summary
Attributes inherited from Capistrano
Instance Method Summary collapse
-
#define_rake_wrapper(task, named_arguments) {|env| ... } ⇒ CapistranoDeprecated
deprecated
Deprecated.
Use Cape::Capistrano#define_rake_wrapper instead.
-
#deprecation ⇒ Deprecation::Base
private
The object in which deprecated API usage is recorded.
Methods inherited from Capistrano
Constructor Details
This class inherits a constructor from Cape::Capistrano
Instance Method Details
#define_rake_wrapper(task, named_arguments) {|env| ... } ⇒ CapistranoDeprecated
Use Cape::Capistrano#define_rake_wrapper instead.
Any parameters that the Rake task has are integrated via environment variables, since Capistrano does not support recipe parameters per se.
Defines a wrapper in Capistrano around the specified Rake task.
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/cape/capistrano_deprecated.rb', line 45 def define_rake_wrapper(task, named_arguments, &block) unless (binding = named_arguments[:binding]) raise ::ArgumentError, ':binding named argument is required' end deprecation.task = task deprecation.named_arguments = named_arguments capistrano_context = binding.eval('self', __FILE__, __LINE__) = named_arguments.reject do |key, value| key == :binding end describe task, capistrano_context implement(task, capistrano_context, , &block) end |
#deprecation ⇒ Deprecation::Base
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
The object in which deprecated API usage is recorded.
64 65 66 |
# File 'lib/cape/capistrano_deprecated.rb', line 64 def deprecation @deprecation ||= Deprecation::CapistranoDeprecatedDefineRakeWrapper.new end |