Method: Bunto::Commands::Clean.remove

Defined in:
lib/bunto/commands/clean.rb

.remove(filename, checker_func: :file?) ⇒ Object



30
31
32
33
34
35
36
37
# File 'lib/bunto/commands/clean.rb', line 30

def remove(filename, checker_func: :file?)
  if File.public_send(checker_func, filename)
    Bunto.logger.info "Cleaner:", "Removing #{filename}..."
    FileUtils.rm_rf(filename)
  else
    Bunto.logger.info "Cleaner:", "Nothing to do for #{filename}."
  end
end