Class: Backsum::Server::Dsl
- Inherits:
-
Object
- Object
- Backsum::Server::Dsl
- Defined in:
- lib/backsum/server.rb
Instance Attribute Summary collapse
-
#instance ⇒ Object
Returns the value of attribute instance.
Instance Method Summary collapse
- #folder(path, options = {}) ⇒ Object
-
#initialize(host, options = {}, &block) ⇒ Dsl
constructor
A new instance of Dsl.
Constructor Details
#initialize(host, options = {}, &block) ⇒ Dsl
Returns a new instance of Dsl.
75 76 77 78 79 80 81 82 |
# File 'lib/backsum/server.rb', line 75 def initialize(host, = {}, &block) self.instance = Server.new self.instance.host = host self.instance.local = [:local] self.instance.username = [:username] instance_eval(&block) if block end |
Instance Attribute Details
#instance ⇒ Object
Returns the value of attribute instance.
73 74 75 |
# File 'lib/backsum/server.rb', line 73 def instance @instance end |
Instance Method Details
#folder(path, options = {}) ⇒ Object
84 85 86 |
# File 'lib/backsum/server.rb', line 84 def folder(path, = {}) self.instance.folders[path] = end |