Dir.foreach("#{new_project_dir}/wp-content/themes") do |item|
next if item == '.' or item == '..'
FileUtils.rm_rf "#{new_project_dir}/wp-content/themes/#{item}" if File.directory?(item)
end
This seemed to work at one point, but now all of the theme directories are returning false to File.directory?