Class: Kiba::Extend::Utils::PreJobNukeTask
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from PreJobTask
#initialize
Class Method Details
.call ⇒ Object
8
9
10
|
# File 'lib/kiba/extend/utils/pre_job_nuke_task.rb', line 8
def call
new.call
end
|
Instance Method Details
#call ⇒ Object
13
14
15
16
17
18
19
20
|
# File 'lib/kiba/extend/utils/pre_job_nuke_task.rb', line 13
def call
return unless runnable?
dirs.each do |dir|
puts "Deleting files from #{dir}..."
Dir.each_child(dir) { |f| FileUtils.rm("#{dir}/#{f}") }
end
end
|