Class: HR_Deploy::CleanOldAssetsTask
- Defined in:
- lib/hr_deploy/tasks/clean_old_assets_task.rb
Instance Attribute Summary
Attributes inherited from Task
#end_time, #error, #start_time
Instance Method Summary collapse
Methods inherited from Task
#initialize, #reversal_instruction, #successful?
Constructor Details
This class inherits a constructor from HR_Deploy::Task
Instance Method Details
#run ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/hr_deploy/tasks/clean_old_assets_task.rb', line 7 def run print_stage 'Cleaning up old assets...' execute_system_command('rake assets:clean') if dry_run? || !confirm? self.success = true return end if confirm_successful?('Old assets cleaned up?') self.success = true else self.success = false self.error = 'Could not clean up old assets' end end |