Class: GitPusshuTen::Commands::Delete
- Defined in:
- lib/gitpusshuten/commands/delete.rb
Instance Attribute Summary
Attributes inherited from Base
#cli, #command, #configuration, #environment, #hooks, #perform_hooks
Instance Method Summary collapse
-
#initialize(*objects) ⇒ Delete
constructor
A new instance of Delete.
-
#perform_! ⇒ Object
Deletes the application directory from the remote server.
Methods inherited from Base
#c, #command_object, description, #e, #error, example, #g, #git, #help, #local, long_description, #message, #perform!, #perform_hooks!, #post_perform!, #pre_perform!, #prompt_for_root_password!, #prompt_for_user_password!, #r, #requires_user_existence!, #silent, #standard, usage, #validate!, #warning, #y, #yes?
Constructor Details
#initialize(*objects) ⇒ Delete
Returns a new instance of Delete.
9 10 11 12 13 |
# File 'lib/gitpusshuten/commands/delete.rb', line 9 def initialize(*objects) super help if e.name.nil? end |
Instance Method Details
#perform_! ⇒ Object
Deletes the application directory from the remote server
17 18 19 20 21 22 23 |
# File 'lib/gitpusshuten/commands/delete.rb', line 17 def perform_! "Are you sure you wish to delete #{y(c.application)} from the #{y(e.name)} environment (#{y(c.ip)})?" if yes? "Deleting #{y(c.application)}." e.delete! end end |