Even more succinct one-liner that works when dir_path is a string:
dir_path
string
Pathname.new(dir_path).each_child(&:unlink)